[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: (Minor?) bugs



On Thu, 2 Nov 2000 21:01:25 +0100
Falko Braeutigam <falko@smb-tec.com> wrote:

> > 3. Whenever I tried to append an XML subtree or a document to an
> > existing document
> > with org.ozoneDB.xml.util.XMLContainer.storeSAX(Node),
> > the following error message appeared:
> > 
> > java.lang.RuntimeException: given node must be of type
> > Node.DOCUMENT_NODE
> 
> Currently it's not possible to add nodes to an existing document via SAX. We
> simple don't know how to find out if and when the SAX stream ends. That is, if
> we store an entire document, then the stream ends when the document node is
> closed. If you just add some nodes to an existing document, then after closing
> one node another node may start. Therefore we allow storing of entire documents
> only (via SAX). Does anybody know how to tackle this one?

I just checked in some code that should do the job. It assumes that SAX storing is finished if the storage of the first given XML tree is finished. A tree can be a whole document, an element and it descendants or just a single event like 'characters'.

Would be great, if somebody could test it (Michael?) and could give me some feedback.

regards,
Conny Krappatsch

-- 
______________________________________________________________________
Conny Krappatsch                              mailto:conny@smb-tec.com
SMB GmbH                                        http://www.smb-tec.com