Re: [Wyonacms-dev] SAX or DOM
Michael Wechner <[email protected]>
| Newsgroups | gmane.comp.cms.wyona.user |
|---|---|
| Message-ID | <[email protected]> |
tarGET-X.com wrote: > Hello group, hello Micheal, > > I found that in the cocoon.xmap: > > Transformers can be placed inside the pipeline between the generator > and the serializer. You may have as many transformers as you > like. Transformers consume SAX events and emmit SAX events. > > The "xslt" transformer is an example of a component with additional > configuration. > > --> So Wyona is using the Simple Application Programming Interface (API) > for Xml (SAX). This is because coocon is using it. The biggest > difference between SAX and the DOM is that SAX is an event driven > interface. > > Is that right? Transformers don't have to be based on SAX. You can also base it on DOM if you want. Please take a look at src/java/org/wyona/cms/cocoon/transformation/IncludeTransformer.java There are a lot of discussions what to use: Advantage SAX: good performance, doesn't consume a lot of memory Advantage DOM: Easy to manipulate nodes The Cocoon guys seem to prefer SAX. I try to be pragmatic which means I take whatever I think fits best for some problem. You can refactor things any time:-) All the best Michael > > > > > _______________________________________________ > WyonaCMS-dev mailing list > [email protected] > http://mail.wyona.org/cgi-bin/mailman/listinfo/wyonacms-dev