InputStream is=Thread.currentThread().getContextClassLoader().getResourceAsStream("config/struts.properties"); Properties p=new Properties(); try { p.load(is); is.close(); } catch (IOException e) { e.printStackTrace(); } System.out.println(p.get("a")); |
|
来自: squarecome > 《我的图书馆》