Here you can find the source of load(Properties properties, String fileName)
Parameter | Description |
---|---|
properties | The properties object to load values from. |
fileName | The name of the properties file. |
private static void load(Properties properties, String fileName)
//package com.java2s; //License from project: Apache License import java.io.FileInputStream; import java.io.IOException; import java.util.Properties; public class Main { /**/* ww w. j a v a2 s .com*/ * Load into the given <i>properties</i> the file from the given <i>fileName</i>. * * @param properties The properties object to load values from. * @param fileName The name of the properties file. */ private static void load(Properties properties, String fileName) { try { properties.load(new FileInputStream(fileName)); } catch (IOException ignored) { throw new RuntimeException("Could not load " + fileName); } } }