public LogAnalyser(String xmlpath) {
try
{
File fl = new File(xmlpath);
if(!fl.exists())
{
System.out.println("Not Find xml file:" + xmlpath);
throw new java.io.FileNotFoundException("Not Find xml file:" + xmlpath);
}
System.out.println("Start reading");
SAXReader reader = new SAXReader();
Document document = reader.read(fl);
}
catch(java.io.FileNotFoundException e)
{
System.out.println("Not Find xml file:" + xmlpath);
}
catch(java.io.IOException e)
{
System.out.println("Not Find xml file:" + xmlpath + e.getMessage());
}
catch(Exception e)
{
e.printStackTrace();
} }
try
{
File fl = new File(xmlpath);
if(!fl.exists())
{
System.out.println("Not Find xml file:" + xmlpath);
throw new java.io.FileNotFoundException("Not Find xml file:" + xmlpath);
}
System.out.println("Start reading");
SAXReader reader = new SAXReader();
Document document = reader.read(fl);
}
catch(java.io.FileNotFoundException e)
{
System.out.println("Not Find xml file:" + xmlpath);
}
catch(java.io.IOException e)
{
System.out.println("Not Find xml file:" + xmlpath + e.getMessage());
}
catch(Exception e)
{
e.printStackTrace();
} }
解决方案 »
- 谁给个JDK源码下载地址,想学习下JAVA内部的源码
- File与FormFile有什么不同?
- 求一个java Socket实例
- 新手ssh开发中的问题。
- 不知文件编码格式,写入数据库中文是乱码。
- 戏服务器端开发工作内容是什么
- 100请教高手,做成这样效果的如何处理。。高分相送
- 为什么用 jdk1.42 编译ejb 文件 总说 找不到 javax.ejb.* 这个包 ,到哪里去下了?
- Myeclipse+weblogic+struts2开发,报NativeMethodAccessorImpl.class错误
- Spring + SpringMVC + JPA(Hibernate)集成环境持久化问题
- 用了struts以后jsp里面的菜单显示不出来了
- 请问如何用JB修改TOMCAT下的server.xml
错误,即使你只操作了一个getRootElement。采用SAX应该可以解决吧
-Xms128m -Xmx512m
set JVM memory allocation pool parameters