Java web项目读取tomcat下的properties或xml配置文件

Java web 项目读取src或者tomcat下class文件夹下的xml文件或者properties文件   //推荐使用此方法 String path = getClass().getClassLoader().getResource("friend.xml").getPath(); //生成一个文件对象: File file = new File(getClass().getClassLo
相关文章
相关标签/搜索