You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Terry Brick <te...@yahoo.com> on 2004/06/30 23:05:44 UTC

Why are ReadDOMSession and WriteDOMSession transformers?

I guess I'm just not grasping some concepts.  Could somebody explain to me why we have
ReadDOMSessionTransformer and WriteDOMSessionTransformer instead of ReadDOMSessionGenerator and
WriteDOMSessionGenerator?
I mean, shouldn't a tranformer take existing XML in the pipeline and transform it using XSL?  Well
my DOM object is in the session, not the pipleline....
I ask this because I have a situation where I need to put a DOM that's in the session into the
pipeline and THEN transform it... but Cocoon is complaining that I'm trying to transform something
without a generator first!  But the XML i need to 'generate' is only accessible by the
'transformer' (ReadDOMSessionTransformer)!

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re: Why are ReadDOMSession and WriteDOMSession transformers?

Posted by Joerg Heinicke <jo...@gmx.de>.
On 30.06.2004 23:05, Terry Brick wrote:

> I guess I'm just not grasping some concepts.  Could somebody explain to me why we have
> ReadDOMSessionTransformer and WriteDOMSessionTransformer instead of ReadDOMSessionGenerator and
> WriteDOMSessionGenerator?
> I mean, shouldn't a tranformer take existing XML in the pipeline and transform it using XSL?  Well
> my DOM object is in the session, not the pipleline....
> I ask this because I have a situation where I need to put a DOM that's in the session into the
> pipeline and THEN transform it... but Cocoon is complaining that I'm trying to transform something
> without a generator first!  But the XML i need to 'generate' is only accessible by the
> 'transformer' (ReadDOMSessionTransformer)!

Yes, you are absolutely correct. This is why I absolutely don't like 
them, they are hacks. The same is true for the SourceWritingTransformer. 
In the meantime there is a valid replacement available with the 
XModuleSource: http://wiki.cocoondev.org/Wiki.jsp?page=XModuleSource.

Joerg

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re: Why are ReadDOMSession and WriteDOMSession transformers?

Posted by Terry Brick <te...@yahoo.com>.
Jeesh, why do I have habit of spending lots of time on something, then giving up and posting to
this group, then immediately afterwords answering my own questin.
Here's the answer...
It looks like what I want to be using is SessionAttributeGenerator.  ReadDOMSessionTransformer can
be used if you want to insert something mid-stream.  I guess I'm still not entirely clear why we
have ReadDOMSessionTransformer instead of using an aggregator.  My assumption is that it's just to
avoid having to use multiple generators and increasing the complexity of your sitemap.

--- Terry Brick <te...@yahoo.com> wrote:
> Correction... this should only apply to ReadDOMSessionTransformer, not
> WriteDOMSessionTransformer.
> 
> --- Terry Brick <te...@yahoo.com> wrote:
> > I guess I'm just not grasping some concepts.  Could somebody explain to me why we have
> > ReadDOMSessionTransformer and WriteDOMSessionTransformer instead of ReadDOMSessionGenerator
> and
> > WriteDOMSessionGenerator?
> > I mean, shouldn't a tranformer take existing XML in the pipeline and transform it using XSL? 
> > Well
> > my DOM object is in the session, not the pipleline....
> > I ask this because I have a situation where I need to put a DOM that's in the session into the
> > pipeline and THEN transform it... but Cocoon is complaining that I'm trying to transform
> > something
> > without a generator first!  But the XML i need to 'generate' is only accessible by the
> > 'transformer' (ReadDOMSessionTransformer)!
> > 
> > __________________________________________________
> > Do You Yahoo!?
> > Tired of spam?  Yahoo! Mail has the best spam protection around 
> > http://mail.yahoo.com 
> > 
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> > For additional commands, e-mail: users-help@cocoon.apache.org
> > 
> > 
> 
> 
> 
> 		
> __________________________________
> Do you Yahoo!?
> Read only the mail you want - Yahoo! Mail SpamGuard.
> http://promotions.yahoo.com/new_mail 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org
> 
> 



		
__________________________________
Do you Yahoo!?
Yahoo! Mail - 50x more storage than other providers!
http://promotions.yahoo.com/new_mail

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re: Why are ReadDOMSession and WriteDOMSession transformers?

Posted by Terry Brick <te...@yahoo.com>.
Correction... this should only apply to ReadDOMSessionTransformer, not WriteDOMSessionTransformer.

--- Terry Brick <te...@yahoo.com> wrote:
> I guess I'm just not grasping some concepts.  Could somebody explain to me why we have
> ReadDOMSessionTransformer and WriteDOMSessionTransformer instead of ReadDOMSessionGenerator and
> WriteDOMSessionGenerator?
> I mean, shouldn't a tranformer take existing XML in the pipeline and transform it using XSL? 
> Well
> my DOM object is in the session, not the pipleline....
> I ask this because I have a situation where I need to put a DOM that's in the session into the
> pipeline and THEN transform it... but Cocoon is complaining that I'm trying to transform
> something
> without a generator first!  But the XML i need to 'generate' is only accessible by the
> 'transformer' (ReadDOMSessionTransformer)!
> 
> __________________________________________________
> Do You Yahoo!?
> Tired of spam?  Yahoo! Mail has the best spam protection around 
> http://mail.yahoo.com 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org
> 
> 



		
__________________________________
Do you Yahoo!?
Read only the mail you want - Yahoo! Mail SpamGuard.
http://promotions.yahoo.com/new_mail 

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org