cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Gary Larsen" <gary.lar...@envisn.com>
Subject Problem in custom Transformer (migrating to 2.1.10)
Date Sun, 21 Jan 2007 21:40:48 GMT
I'm now trying the dev-list for this.  Thanks for any ideas.

I'm upgrading Cocoon from 2.1.7 to 2.1.10 and having a problem with a custom
transformer.

The transformer is not sending events back to the pipeline.  Putting a
LogTransformer before the custom transformer logs events, but when using it
after no events are logged.

The transformer is maybe to simple for 2.1.10?

public class NamespaceDecoratorTransformer extends AbstractTransformer {

    private SaxDecorator decorator = null;

    public void setup(SourceResolver resolver, Map objectModel, String src,
Parameters par)
            throws ProcessingException, SAXException, IOException {

        if (super.contentHandler != null) {
            this.decorator = new SaxDecorator(super.contentHandler);
        }
    }

SaxDecorator is a java ContentHandler which just adds uri info to elements.
>From the application log I can see both classes handling events:

DEBUG 64406 [http-8080-Processor25] SaxDecorator: startDocument called 
DEBUG 64406 [http-8080-Processor25] NamespaceDecoratorTransformer:
startDocument() called
DEBUG 64547 [http-8080-Processor25] NamespaceDecoratorTransformer:
startElement() called - loc:userSession 
DEBUG 64547 [http-8080-Processor25] SaxDecorator: startElement -
localName:userSession 
DEBUG 64547 [http-8080-Processor25] NamespaceDecoratorTransformer:
startElement() called - loc:adminLoggedOn 
DEBUG 64547 [http-8080-Processor25] SaxDecorator: startElement -
localName:adminLoggedOn 
DEBUG 64562 [http-8080-Processor25] NamespaceDecoratorTransformer:
startElement() called - loc:appStatus 
DEBUG 64562 [http-8080-Processor25] SaxDecorator: startElement -
localName:appStatus

This works fine in 2.1.7.  

Thanks,
Gary


Mime
View raw message