On Monday 22 April 2002 01:36 pm, Simon Brooke wrote:
> I have a *lot* of classes which implement this interface.To plug them
> into Cocoon I need to generate SAX events and currently I don't.
> Obviously generating SAX events as the document is being built is going
> to be quicker than building a document tree and then tree-walking it to
> generate the SAX events, so if I decide that Cocoon is the right road
> to go down I've got a lot of rewriting to do. But as a quick fix, does
> someone have a class which implements
> org.apache.cocoon.generation.Generator, and which (in its generate()
> method) walks a DOM tree constructed by something else? It would save
> me a lot of grief.

Look at the
org.apache.cocoon.xml.AbstractSAXFragment
which uses
org.apache.cocoon.xml.dom.DOMBuilder
to easily convert a org.w3c.dom.Node to SAX2 events.
-pete

-- 
peter royal -> [EMAIL PROTECTED]

---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>

Reply via email to