cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andrew Stevens <>
Subject RE: Accessing sitemap label-attribute in TraxTransformer
Date Fri, 30 Nov 2007 13:32:27 GMT

You seem to be missing the point of dependency injection - the TraxTransformer doesn't 
look up its logger or specify its name or anything like that.  It just declares "I want a
(by implementing a "loggable" interface), and the component manager gives it one.
So to do what you are suggesting would involve changing the component manager, not
your transformer, so that it uses the label attribute or whatever to determine the logger

that it passes into the transformer after creating it.

What are you trying to achieve, though?  If you just want your transformer to use a different
name/category to the default TraxTransformer, why not just specify a different logger=...
parameter when you declare your component in the map:transformers section of your

--  Open source java Sudoku solver

> Date: Fri, 30 Nov 2007 10:31:56 +0100
> From:
> hallo out there,
> does anybody know if there is a possibility to access the "label"-attribute from map:transform
inside the
> TraxTransformer (java-code)?
> I wrote my own TraxTransformer and I want to use the sitemap "label"-attribute as a logger
> Greetings
> Janne Olesen

Celeb spotting – Play CelebMashup and win cool prizes
To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message