728x90
반응형
import java.io.FileInputStream;
import java.io.InputStream;
import java.util.Properties;
public class ReadProperties {
public static Properties getInfo(String path){
Properties batchProps = new Properties();
try
{
InputStream is =
new FileInputStream(path);
batchProps.load(is);
}
catch (Exception e)
{
System.out.println("Error. : Can't read the config.properties file.");
return null;
}
return batchProps;
}
}
728x90
반응형