SV: [jdom-interest] UnknownHostException with SAXBuilder

Per Norrman pernorrman at
Wed Feb 4 06:08:52 PST 2004

When given a File object, SAXBuilder calls File#toURL and then creates
an InputSource from that URL, and
hands it over to the XMLReader (the underlying parser).  You can always
check that you can open a connection
to this URL, yourself:

-----Ursprungligt meddelande-----
Från: jdom-interest-admin at [mailto:jdom-interest-admin at]
För Daniel, Gillian
Skickat: den 4 februari 2004 14:12
Till: jdom-interest at
Ämne: [jdom-interest] UnknownHostException with SAXBuilder

Hi there,

This is my first post to the JDOM mailing list, as up till now I have
experienced no problems using JDOM.  However I have been using weblogic
5/8.1 up until now.


I am currently part of a team writing an application which reads in
configuration files which are in xml files.  For development purposes we
are using Apache Tomcat 5.0.16, with Java Standard Edition and
Java Enterprise Edition 1.4


When I call on any of the configuration files, I get
this error


Exception: D


Now my file is on my D: drive, in a config folder, and the path to this
config folder is in a properties file.  The file path is being read in
correctly, as I have added debug in to prove this.  I can create a File
from this path and the configuration file name, but when I pass this
File into the  get the UnknowHostException.  I
know it falls over here, as I have debug following this line and this is
never output.


Here is my code:


File configFile = new File(thePath+buildFile);

System.out.println("BuildParsingServiceImpl.getRoot(): configFile “ +

Document document =;
System.out.println("BuildParsingServiceImpl.getRoot(): Document Created:


The result of adding thePath + buildFile is 




I honestly have no idea what is wrong, I have tried making the File a
URL, I have tried adding file: in front of thePath, but still nothing.


Can somebody please indicate where I am going wrong?


Any help would be greatly appreciated, thank-you for taking the time to
read this,


-------------- next part --------------
An HTML attachment was scrubbed...

More information about the jdom-interest mailing list