cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stefano Mazzocchi <stef...@apache.org>
Subject Problem with Xalan1 and namespaces
Date Mon, 11 Sep 2000 11:54:29 GMT
Scott,

we are having problems with latest Xalan released and namespaces, could
you give us a hand identifying the problem?

With XT it works no problem so either it's a problem with Xalan or it's
a problem with the wrapper/liaison that we wrote in Cocoon2.

Anyway, I wanted to use Xalan2 instead of Xalan1, can you give us an
update on its usability/functionality/stability?

TIA

Nicola Ken Barozzi wrote:

> > First of all, the exmple should work too, but it doesn't, so it seems we have
> > a bug here.
> > If I call the process method in the XalanTransformer to System.out instead of
> > returning the DocumentHandler, it works!
> >
> >     processor.process(new XSLTInputSource("foo.xml"),
> >                       style,
> >                       new XSLTResultTarget(System.out));
> >
> > (I called the test sitemap foo.xml)
> >
> > So it seems that namespace uri is stripped off if transformation is giuded by
> > external sax but not using the process method.
> 
> Maybe I have something.
> In class StylesheetRoot (xalan) method
>   public void process( XSLTProcessor iprocessor, Node sourceTree,
>                        XSLTResultTarget outputTarget)
> (called by all other process in same class and processors)
> I found this note:
> 
>         // Needs work: We have to put the extension namespaces
>         // into the liaison's table.  We wouldn't have to do this
>         // if the stylesheet handled it's own extensions, which
>         // I'll fix on a later date.
>         Enumeration keys = m_extensionNamespaces.keys();
>         while(keys.hasMoreElements())
>         {
>           Object key = keys.nextElement();
>           // System.out.println("Putting ext namespace: "+key);
>           processor.getExecContext().addExtensionNamespace ((String)key,
>                                                             (ExtensionFunctionHandler)m_extensionNamespaces.get(key));
>         }
> 
> Maybe I'm wrong, but it seems that namespaces are truly set-up only by this
> method, hence the problem when directly starting it all via SAX.

-- 
Stefano Mazzocchi      One must still have chaos in oneself to be
                          able to give birth to a dancing star.
<stefano@apache.org>                             Friedrich Nietzsche
--------------------------------------------------------------------
 Missed us in Orlando? Make it up with ApacheCON Europe in London!
------------------------- http://ApacheCon.Com ---------------------



Mime
View raw message