Skip to Content.
Sympa Menu

xom-interest - Re: [XOM-interest] Recursion

xom-interest AT lists.ibiblio.org

Subject: XOM API for Processing XML with Java

List archive

Chronological Thread  
  • From: jcowan AT reutershealth.com
  • To: "Bradley S. Huffman" <hip AT cs.okstate.edu>
  • Cc: xom-interest AT lists.ibiblio.org
  • Subject: Re: [XOM-interest] Recursion
  • Date: Tue, 9 Mar 2004 14:04:39 -0500

Bradley S. Huffman scripsit:

> > This algorithm needs to be adjusted somewhat for the serialization use
> > case.
> > The key difference is that a serializer needs to process an element
> > twice, once for the start-tag before the children are processed and
> > once for the end-tag after the children are processed.

Just insert the end-tag processing into 4.

> Step 4 looks like a infinite loop to me. I think it should be "move to
> the parent, go to step 3".

Quite right. So step 4 should be:

If the current node is not the initial node:
move to the parent, do end-element processing if any, go to
step 3.

--
Income tax, if I may be pardoned for saying so, John Cowan
is a tax on income. --Lord Macnaghten (1901)
jcowan AT reutershealth.com




Archive powered by MHonArc 2.6.24.

Top of Page