67,513
社区成员
发帖
与我相关
我的任务
分享
InputStream is = null;
Properties prpts = new Properties();
try {
String path = "c:/mypro.properties";
is = new FileInputStream(confPath);
prpts.load(is);
} catch (IOException e) {
} finally {
IOUtils.closeQuietly(is);
}
String indexpath = prpts.getProperty("my.path"));
String indexpath = props.getProperty("my.path");
System.out.println(indexpath);
没有问题,输出的是c:/tmypath