[jdom-interest] Re: jdom-interest Digest, Vol 6, Issue 1
Kashif Riaz
kash.riaz at gmail.com
Tue Jan 4 03:08:33 PST 2005
Hi,
You can simply use the URI of the DTD as the second parameter in the
build() method:
SAXBuilder builder = new SAXBuilder();
Document doc = builder.build(myInputStream, "file:///" + fullPathToDtd
+ dtdFileName);
API: http://www.jdom.org/docs/apidocs/org/jdom/input/SAXBuilder.html
That should work.
Kashif.
On Sun, 2 Jan 2005 12:00:03 -0800, jdom-interest-request at jdom.org
<jdom-interest-request at jdom.org> wrote:
> Send jdom-interest mailing list submissions to
> jdom-interest at jdom.org
>
> To subscribe or unsubscribe via the World Wide Web, visit
> http://www.jdom.org/mailman/listinfo/jdom-interest
> or, via email, send a message with subject or body 'help' to
> jdom-interest-request at jdom.org
>
> You can reach the person managing the list at
> jdom-interest-owner at jdom.org
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of jdom-interest digest..."
>
> Today's Topics:
>
> 1. validate document without DOCTYPE declaration (John C Cartwright)
>
> ----------------------------------------------------------------------
>
> Message: 1
> Date: Sat, 01 Jan 2005 20:32:15 -0700
> From: "John C Cartwright" <John.C.Cartwright at noaa.gov>
> Subject: [jdom-interest] validate document without DOCTYPE declaration
> To: jdom-interest at jdom.org
> Message-ID: <9fdfd1d4.d1d49fdf at noaa.gov>
> Content-Type: text/plain; charset=us-ascii
>
> Hello All,
>
> I'm trying to find a way to validate a document that does not include the DOCTYPE
> declaration. The URL for the DTD is known at runtime, but is not imbeded in the XML
> document.
>
> Can anyone tell me a way to do this?
>
> Thanks!
>
> -- john
>
> ------------------------------
>
> _______________________________________________
> To control your jdom-interest membership:
> http://www.jdom.org/mailman/options/jdom-interest/youraddr@yourhost.com
>
> End of jdom-interest Digest, Vol 6, Issue 1
> *******************************************
>
More information about the jdom-interest
mailing list