//读操作 Properties properties = new Properties(); try { properties.load(new FileInputStream("filename.properties")); } catch (IOException e) { // implement catch logic } //写操作 Properties properties = new Properties(); try { properties.store( new FileOutputStream("filename.properties"), null); } catch (IOException e) { // implement catch logic }
原创文章,作者:奋斗,如若转载,请注明出处:https://blog.ytso.com/10961.html