  | |  | Xalan extension functions | Xalan extension functions 2007-04-27 - By Wade, John F. (MSFC-NAS902099)[TBE]
As long as we're on the topic of XALAN extension functions, I too am looking for some help. I've got an existing XALAN-J based system (I didn't create it) that I'm trying to add on to. I want to create a simple extension function in JAVA. The XALAN-J documentation says stuff written in JAVA doesn't require BSF . So - I went to work on one of the XSLs: added a simple namespace and defined a component as in the example at http://xml.apache.org/xalan-j/extensions.html#ex -java I wrote and compiled an extension function; currently just of the "Hello, world" sort. So far, so good. Problem arises when I try and use the extension function in something like <xsl :value-of select="mytest:hello()"/> XALAN throws a "can't find the class" exception no matter where I put the .class file. Those folks out there with some experience implementing JAVA extensions - I'd be grateful for some help figuring this out. I'm sure it's something very simple, but I don't know where to look next. ********************************* John F. Wade, PE MSFC iPV Integration Lead
<HTML dir=ltr><HEAD> <META http-equiv=Content-Type content="text/html; charset=unicode"> <META content="MSHTML 6.00.2900.3059" name=GENERATOR></HEAD> <BODY> <DIV id=idOWAReplyText82743 dir=ltr> <DIV dir=ltr><FONT face=Arial color=#000000 size=2>As long as we're on the topic of XALAN extension functions, I too am looking for some help. <FONT face=Arial size=2>I've got an existing XALAN-J based system (I didn 't create it) that I'm trying to add on to. </FONT></FONT><FONT face =Arial size=2>I want to create a simple extension function in JAVA. </FONT> <FONT face=Arial size=2> The XALAN-J documentation says stuff written in JAVA doesn't require BSF.</FONT></DIV> <DIV dir=ltr><FONT face=Arial size=2></FONT> </DIV> <DIV dir=ltr><FONT face=Arial size=2>So - I went to work on one of the XSLs: added a simple namespace and defined a component as in the example at <A href="http://xml.apache.org/xalan-j/extensions.html#ex-java">http://xml.apache .org/xalan-j/extensions.html#ex-java</A> I wrote and compiled an extension function; currently just of the "Hello, world" sort. So far, so good .</FONT></DIV> <DIV dir=ltr><FONT face=Arial size=2></FONT> </DIV> <DIV dir=ltr><FONT face=Arial size=2>Problem arises when I try and use the extension function in something like <xsl:value-of select="mytest :hello()"/> XALAN throws a "can't find the class" exception no matter where I put the .class file.</FONT></DIV> <DIV dir=ltr><FONT face=Arial size=2></FONT> </DIV> <DIV dir=ltr><FONT face=Arial size=2>Those folks out there with some experience implementing JAVA extensions - I'd be grateful for some help figuring this out. I'm sure it's something very simple, but I don't know where to look next. </FONT></DIV> <DIV dir=ltr><FONT face=Arial color=#000000 size=2></FONT> </DIV></DIV> <DIV id=idSignature97637 dir=ltr> <DIV><FONT face=Arial color=#000000 size=2>*********************************< /FONT></DIV> <DIV><FONT face=Arial size=2>John F. Wade, PE</FONT></DIV> <DIV><FONT face=Arial size=2>MSFC iPV Integration Lead</FONT></DIV> <DIV> </DIV> <DIV> </DIV></DIV></BODY></HTML>
|
|
 |