Jason --
Hi. The problem is that we don't currently support DocumentFragment as
an argument in a java extension for receiving an RTF. I seem to recall
that there was a good reason for this but I don't remember that reason
at the moment. So, I'll do some more thinking and either come up with
the reason or add in the support for the java argument being a
DocumentFragment.
In the meantime, can you substitute a NodeIterator or NodeList or Node?
The Node will get you the first child of the DocumentFragment.
Gary
jason heddings wrote:
>
> Hello!
>
> I am trying to create an extension that will accept a Result Tree
> Fragment as it's argument. From the Xalan Extensions doc on the site, I
> gathered this is of type org.w3c.dom.DocumentFragment and I created a
> method that accepts this argument. The processor is unable to find this
> method, however.
>
> As a sanity check just to make sure that the class and method were
> found, I changed the method to accept a String and it worked fine.
>
> <java-source>
>
> public String parse( DocumentFragment frag ) {
> return "running parse( )" ;
> }
>
> </java-source>
>
> <xsl-source>
>
> <xsl:variable name="tree-frag">
> <new-element>
> <child />
> </new-element>
> </xsl:variable>
>
> <xsl:value-of select="ext:parse( $tree-frag )" />
>
> </xsl-source>
>
> Should this work?
>
> Thanks in advance for any help!
> --jah