你可以将InputStream传递给Property,因此你的文件几乎可以在任何地方,并且可以调用任何东西。
Properties properties = new Properties();try { properties.load(new FileInputStream("path/filename"));} catch (IOException e) { ...}迭代为:
for(String key : properties.stringPropertyNames()) { String value = properties.getProperty(key); System.out.println(key + " => " + value);}


