extending the org.apache.xalan.extensions.ExtensionHandlerJavaClass

Adrian Herscu <[email protected]>
Newsgroups gmane.text.xml.xalan.java.user
Message-ID <[email protected]>
Hi all,

I am trying to enhance the readability of my XSL code.
One of the options is to reduce things like named template calls to 
function calls; for example:

<xsl:variable name="foo">
   <xsl:call-template name="getFooFrom">
     <xsl:with-param name="moo" select="$moo" />
   </xsl:call-template>
</xsl:variable>

can be reduced to:

<xsl:variable name="foo" select="my:getFooFrom($moo)" />

which is shorter and more readable.

However this requires the re-implementation of each named template in 
Java. I would like to find a way to make it work without providing Java 
implementations. Hence I am looking to override the 
ExtensionHandlerJavaClass::callFunction() method in order to make it 
check whether there is a 'getFooFrom' template and call it as it would 
be called by an xsl:call-template. What I have found so far is that the 
ExtensionHandlerJavaClass is hardcoded in the ExtensionNamespacesManager 
class :( Do I miss something?

Adrian.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.