Really?  That's what I'm doing, but I thought it would just be a temporary
hack.  :-(

> -----Original Message-----
> From: Sean Kelly [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, October 18, 2000 12:08 PM
> To: general@xml.apache.org; [EMAIL PROTECTED]
> Cc: xerces-j-dev@xml.apache.org
> Subject: Re: Question about document type nodes and JAXP
>
>
> > OK, how do I get the first instance of DOMImplementation so I can create
> the
> > DocumentType before I create the Document?  I can only find a
> way to get a
> > DOMImplementation if I already have a Document.
>
> Document toss = new org.apache.xerces.dom.DocumentImpl();
> DOMImplementation impl = toss.getImplementation();
> DocumentType type = impl.createDocumentType("root",
>   "-//MyOrg//DTD Root 1.0//EN", http://my.org/root.dtd);
> Document doc = impl.createDocument("rootns", "root", type);
> // then add nodes to "doc"
>
> --Sean
>
>
>
> ---------------------------------------------------------------------
> In case of troubles, e-mail:     [EMAIL PROTECTED]
> To unsubscribe, e-mail:          [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>

Reply via email to