[jdom-interest] DOMBuilder?

Daniel L. Rall dlr at finemaltcoding.com
Tue Aug 8 10:31:10 PDT 2000


Richard Scales wrote:
> 
> When trying to use a FileStream from a URL to build a document using the
> following code:-
> 
>         // The URL of the XML file
>         String url = "http://p.moreover.com/cgi-local/page?index_bookreviews+rss";
> 
>         // initialise the document
>         doc = new Document(new Element("rootElement"));
> 
>         // Create our builder
>         DOMBuilder builder = new DOMBuilder();
> 
>         // Build the Document
>       Document doc = builder.build(new URL(url).openStream());
> 
> I get the following error :-
> 
>          method build(java.io.InputStream) not found in class
> org.jdom.input.DOMBuilder
> 
> Well that is the correct object to pass to the method and it works OK if I
> use a file as in the example so does anyone know
> what is going on?

Could you possibly have an older version of the classes or JAR in your
CLASSPATH, Richard?  According to today's CVS, that method signature
should be fine.

jdom/src/java/org/jdom/input/DOMBuilder.java:    public Document
build(InputStream in) throws JDOMException
-- 

Daniel Rall <dlr at finemaltcoding.com>



More information about the jdom-interest mailing list