echo ""; echo ""; echo ""; echo ""; if(!is_admin){echo "";} » 使用JDom进行XML分析时的一个小错误以及解决办法 仲子说

2009-01-18

使用JDom进行XML分析时的一个小错误以及解决办法

Posted in Java at 8:59 Author:仲远

标签:

???JDom??XML?????????????

java.net.SocketException: Unexpected end of file from server
 at sun.net.www.http.HttpClient.parseHTTPHeader(Unknown Source)
 at sun.net.www.http.HttpClient.parseHTTP(Unknown Source)
 at sun.net.www.http.HttpClient.parseHTTPHeader(Unknown Source)
 at sun.net.www.http.HttpClient.parseHTTP(Unknown Source)
 at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source)
 at org.apache.xerces.impl.XMLEntityManager.setupCurrentEntity(Unknown Source)
 at org.apache.xerces.impl.XMLEntityManager.startEntity(Unknown Source)
 at org.apache.xerces.impl.XMLEntityManager.startDTDEntity(Unknown Source)
 at org.apache.xerces.impl.XMLDTDScannerImpl.setInputSource(Unknown Source)
 at org.apache.xerces.impl.XMLDocumentScannerImpl$DTDDispatcher.dispatch(Unknown Source)
 at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
 at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
 at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
 at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
 at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
 at org.jdom.input.SAXBuilder.build(SAXBuilder.java:453)
 at org.jdom.input.SAXBuilder.build(SAXBuilder.java:891)
 at cn.edu.ruc.web.wrappers.JDomWrapper.getRootElement(JDomWrapper.java:36)
 at cn.edu.ruc.web.wrappers.JDomWrapper.getText(JDomWrapper.java:75)
 at cn.edu.ruc.web.WebsiteXMLBuild.main(WebsiteXMLBuild.java:131)

?????????????????JDom????????????????????????????XML????????????????????????????????????????????????

????XML?????????XML?????????HTML??????DTD?????

<!DOCTYPE HTML PUBLIC “-//W3C//DTD HTML 4.01 Transitional//EN”
“http://www.w3.org/TR/html4/loose.dtd”>

??????????JDom????????????loose.dtd???????????

???????????XML??????JDom?????????XML????

本文可以自由转载,转载时请保留全文并注明出处:
转载自仲子说 [ http://www.wangzhongyuan.com/ ]
原文链接:

Leave a Comment

*
To prove you're a person (not a spam script), type the security text shown in the picture. Click here to regenerate some new text.
Click to hear an audio file of the anti-spam word