Re: XSLT import/include errors

2013-06-21 Thread gelo1234
Solution: If you want to call Java functions freely from C3 XSLT, use older
Saxon implementation.
Version 9.1 works perfectly!

Greetings,
Greg


2013/6/21 gelo1234 

> Looks like Saxon-HE doesn't support anymore calling Java functions that
> way:
>
>
> http://saxon-xslt-and-xquery-processor.13853.n7.nabble.com/XSLT-2-0-Saxon-9-HE-and-call-java-functions-td4347.html
>
> But there are available in PE and EE versions, huh
>
> Greetings,
> Greg
>
>
>
> 2013/6/21 gelo1234 
>
>> Thanks for the tip. Unfortunately it doesn't work with:
>> Saxon-HE-9.5.0.2.jar :(
>>
>> Greetings,
>> Greg
>>
>>
>> 2013/6/21 Robby Pelssers 
>>
>>>  That is possible but the how-to part depends on the Saxon version you
>>> are using.  You will need to dive into how to write extension functions for
>>> that particular implementation.
>>>
>>>  I used it a number of times with Saxon 8.7
>>>
>>>
>>> http://robbypelssers.blogspot.nl/2012/10/creating-unix-timestamp-with-xslt20.html
>>>
>>>
>>> http://robbypelssers.blogspot.nl/2011/09/power-of-apache-cocoon-xquery-and-xslt.html
>>>
>>>  But i never tried with the latest version of Saxon which works
>>> differently.
>>>
>>>  Robby
>>>  --
>>> *Van:* gelo1234 [gelo1...@gmail.com]
>>> *Verzonden:* vrijdag 21 juni 2013 15:23
>>> *To:* Cocoon Users
>>> *Onderwerp:* Re: XSLT import/include errors
>>>
>>>  OK, one more question. Is it possible with Saxon/Xalan in C3 to
>>> invoke external Java function ?
>>> I can't get it working:
>>>
>>> http://www.w3.org/1999/XSL/Transform";
>>> version="1.0"
>>> xmlns:utils="java:org.example.Utils"
>>> exclude-result-prefixes="utils">
>>>
>>>  
>>>
>>>   
>>>
>>>   
>>> >> select="utils:exists($fileName)"/>
>>>   
>>>  
>>>
>>>  
>>>
>>>  Tried Xalan, tried Saxon. Both generates some strange errors with XML
>>> Document.
>>>
>>>  Greetings,
>>> Greg
>>>
>>>
>>> 2013/6/20 gelo1234 
>>>
  The latest Saxon got the same _global_ variable context scope and
 doesn't allow overriding xsl:variables.
  OK, I will fix that :)

  Greetings,
 Greg


 2013/6/20 gelo1234 

>
> Thank you! I will try to bring back Saxon :)
>
>  Greetings,
> Greg
>
>
>This was discused before in the mailing list [1], it's a two step
>> process
>>
>> * Add saxon dependency to pom file. [2]
>>
>>  I think it's better to try Saxon directly if you used to work with
>> it. Xalan is usually faster but as you have to migrate already made
>> templates from Saxon IMO it's better to switch the engine.
>>
>> [1] http://mvnrepository.com/artifact/net.sf.saxon/Saxon-HE
>> [2]
>> http://cocoon.markmail.org/message/mjuftsfwdxmnc5fn?q=saxon#query:saxon+page:1+mid:fe2faygf7jdfrzb3+state:results
>>
>>
>>
>

>>>  *The Future Group, dé maat in ondernemen*
>>>
>>>
>>>   [image: The Future Group]  [image:
>>> The Future Group kantoor]   Röntgenlaan 27 | 2719 DX Zoetermeer [image:
>>> Mobiel nummer] 06 15879926  [image: Web-site]
>>> http://www.the-future-group.com [image: E-mail adres]
>>> robby.pelss...@the-future-group.com  [image: Telefoonnummer]   +31
>>> (0)79 - 363 2905 [image: LinkedIn account]   [image: Twitteraccount]
>>> http://twitter.com/futuregroup
>>>
>>
>>
>


Re: XSLT import/include errors

2013-06-21 Thread gelo1234
Looks like Saxon-HE doesn't support anymore calling Java functions that way:

http://saxon-xslt-and-xquery-processor.13853.n7.nabble.com/XSLT-2-0-Saxon-9-HE-and-call-java-functions-td4347.html

But there are available in PE and EE versions, huh

Greetings,
Greg



2013/6/21 gelo1234 

> Thanks for the tip. Unfortunately it doesn't work with:
> Saxon-HE-9.5.0.2.jar :(
>
> Greetings,
> Greg
>
>
> 2013/6/21 Robby Pelssers 
>
>>  That is possible but the how-to part depends on the Saxon version you
>> are using.  You will need to dive into how to write extension functions for
>> that particular implementation.
>>
>>  I used it a number of times with Saxon 8.7
>>
>>
>> http://robbypelssers.blogspot.nl/2012/10/creating-unix-timestamp-with-xslt20.html
>>
>>
>> http://robbypelssers.blogspot.nl/2011/09/power-of-apache-cocoon-xquery-and-xslt.html
>>
>>  But i never tried with the latest version of Saxon which works
>> differently.
>>
>>  Robby
>>  --
>> *Van:* gelo1234 [gelo1...@gmail.com]
>> *Verzonden:* vrijdag 21 juni 2013 15:23
>> *To:* Cocoon Users
>> *Onderwerp:* Re: XSLT import/include errors
>>
>>  OK, one more question. Is it possible with Saxon/Xalan in C3 to
>> invoke external Java function ?
>> I can't get it working:
>>
>> http://www.w3.org/1999/XSL/Transform";
>> version="1.0"
>> xmlns:utils="java:org.example.Utils"
>> exclude-result-prefixes="utils">
>>
>>  
>>
>>   
>>
>>   
>> > select="utils:exists($fileName)"/>
>>   
>>  
>>
>>  
>>
>>  Tried Xalan, tried Saxon. Both generates some strange errors with XML
>> Document.
>>
>>  Greetings,
>> Greg
>>
>>
>> 2013/6/20 gelo1234 
>>
>>>  The latest Saxon got the same _global_ variable context scope and
>>> doesn't allow overriding xsl:variables.
>>>  OK, I will fix that :)
>>>
>>>  Greetings,
>>> Greg
>>>
>>>
>>> 2013/6/20 gelo1234 
>>>

 Thank you! I will try to bring back Saxon :)

  Greetings,
 Greg


This was discused before in the mailing list [1], it's a two step
> process
>
> * Add saxon dependency to pom file. [2]
>
>  I think it's better to try Saxon directly if you used to work with
> it. Xalan is usually faster but as you have to migrate already made
> templates from Saxon IMO it's better to switch the engine.
>
> [1] http://mvnrepository.com/artifact/net.sf.saxon/Saxon-HE
> [2]
> http://cocoon.markmail.org/message/mjuftsfwdxmnc5fn?q=saxon#query:saxon+page:1+mid:fe2faygf7jdfrzb3+state:results
>
>
>

>>>
>>  *The Future Group, dé maat in ondernemen*
>>
>>
>>   [image: The Future Group]  [image:
>> The Future Group kantoor]   Röntgenlaan 27 | 2719 DX Zoetermeer [image:
>> Mobiel nummer] 06 15879926  [image: Web-site]
>> http://www.the-future-group.com [image: E-mail adres]
>> robby.pelss...@the-future-group.com  [image: Telefoonnummer]   +31 (0)79
>> - 363 2905 [image: LinkedIn account]   [image: Twitteraccount]
>> http://twitter.com/futuregroup
>>
>
>


Re: XSLT import/include errors

2013-06-21 Thread gelo1234
Thanks for the tip. Unfortunately it doesn't work with:
Saxon-HE-9.5.0.2.jar :(

Greetings,
Greg


2013/6/21 Robby Pelssers 

>  That is possible but the how-to part depends on the Saxon version you
> are using.  You will need to dive into how to write extension functions for
> that particular implementation.
>
>  I used it a number of times with Saxon 8.7
>
>
> http://robbypelssers.blogspot.nl/2012/10/creating-unix-timestamp-with-xslt20.html
>
>
> http://robbypelssers.blogspot.nl/2011/09/power-of-apache-cocoon-xquery-and-xslt.html
>
>  But i never tried with the latest version of Saxon which works
> differently.
>
>  Robby
>  --
> *Van:* gelo1234 [gelo1...@gmail.com]
> *Verzonden:* vrijdag 21 juni 2013 15:23
> *To:* Cocoon Users
> *Onderwerp:* Re: XSLT import/include errors
>
>  OK, one more question. Is it possible with Saxon/Xalan in C3 to
> invoke external Java function ?
> I can't get it working:
>
> http://www.w3.org/1999/XSL/Transform";
> version="1.0"
> xmlns:utils="java:org.example.Utils"
> exclude-result-prefixes="utils">
>
>  
>
>   
>
>   
>  select="utils:exists($fileName)"/>
>   
>  
>
>  
>
>  Tried Xalan, tried Saxon. Both generates some strange errors with XML
> Document.
>
>  Greetings,
> Greg
>
>
> 2013/6/20 gelo1234 
>
>>  The latest Saxon got the same _global_ variable context scope and
>> doesn't allow overriding xsl:variables.
>>  OK, I will fix that :)
>>
>>  Greetings,
>> Greg
>>
>>
>> 2013/6/20 gelo1234 
>>
>>>
>>> Thank you! I will try to bring back Saxon :)
>>>
>>>  Greetings,
>>> Greg
>>>
>>>
>>>This was discused before in the mailing list [1], it's a two step
 process

 * Add saxon dependency to pom file. [2]

  I think it's better to try Saxon directly if you used to work with
 it. Xalan is usually faster but as you have to migrate already made
 templates from Saxon IMO it's better to switch the engine.

 [1] http://mvnrepository.com/artifact/net.sf.saxon/Saxon-HE
 [2]
 http://cocoon.markmail.org/message/mjuftsfwdxmnc5fn?q=saxon#query:saxon+page:1+mid:fe2faygf7jdfrzb3+state:results



>>>
>>
>  *The Future Group, dé maat in ondernemen*
>
>
>   [image: The Future Group]  [image: The
> Future Group kantoor]   Röntgenlaan 27 | 2719 DX Zoetermeer [image:
> Mobiel nummer] 06 15879926  [image: Web-site]
> http://www.the-future-group.com [image: E-mail adres]
> robby.pelss...@the-future-group.com  [image: Telefoonnummer]   +31 (0)79
> - 363 2905 [image: LinkedIn account]   [image: Twitteraccount]
> http://twitter.com/futuregroup
>


RE: XSLT import/include errors

2013-06-21 Thread Robby Pelssers
That is possible but the how-to part depends on the Saxon version you are 
using.  You will need to dive into how to write extension functions for that 
particular implementation.

I used it a number of times with Saxon 8.7

http://robbypelssers.blogspot.nl/2012/10/creating-unix-timestamp-with-xslt20.html

http://robbypelssers.blogspot.nl/2011/09/power-of-apache-cocoon-xquery-and-xslt.html

But i never tried with the latest version of Saxon which works differently.

Robby

Van: gelo1234 [gelo1...@gmail.com]
Verzonden: vrijdag 21 juni 2013 15:23
To: Cocoon Users
Onderwerp: Re: XSLT import/include errors

OK, one more question. Is it possible with Saxon/Xalan in C3 to invoke external 
Java function ?
I can't get it working:

http://www.w3.org/1999/XSL/Transform"; version="1.0"
xmlns:utils="java:org.example.Utils"
exclude-result-prefixes="utils">



 

 
   
 




Tried Xalan, tried Saxon. Both generates some strange errors with XML Document.

Greetings,
Greg


2013/6/20 gelo1234 mailto:gelo1...@gmail.com>>
The latest Saxon got the same _global_ variable context scope and doesn't allow 
overriding xsl:variables.
OK, I will fix that :)

Greetings,
Greg


2013/6/20 gelo1234 mailto:gelo1...@gmail.com>>

Thank you! I will try to bring back Saxon :)

Greetings,
Greg


This was discused before in the mailing list [1], it's a two step process

* Add saxon dependency to pom file. [2]

I think it's better to try Saxon directly if you used to work with it. Xalan is 
usually faster but as you have to migrate already made templates from Saxon IMO 
it's better to switch the engine.

[1] http://mvnrepository.com/artifact/net.sf.saxon/Saxon-HE
[2] 
http://cocoon.markmail.org/message/mjuftsfwdxmnc5fn?q=saxon#query:saxon+page:1+mid:fe2faygf7jdfrzb3+state:results






The Future Group, dé maat in ondernemen



[The Future Group][The Future Group kantoor]  
Röntgenlaan 27 | 2719 DX Zoetermeer [Mobiel nummer] 
06 15879926
[Web-site]  http://www.the-future-group.com [E-mail adres]  
robby.pelss...@the-future-group.com
[Telefoonnummer]+31 (0)79 - 363 2905[LinkedIn account]
[Twitteraccount]http://twitter.com/futuregroup




Re: XSLT import/include errors

2013-06-21 Thread gelo1234
OK, one more question. Is it possible with Saxon/Xalan in C3 to invoke
external Java function ?
I can't get it working:

http://www.w3.org/1999/XSL/Transform";
version="1.0"
xmlns:utils="java:org.example.Utils"
exclude-result-prefixes="utils">



 

 
   
 




Tried Xalan, tried Saxon. Both generates some strange errors with XML
Document.

Greetings,
Greg


2013/6/20 gelo1234 

> The latest Saxon got the same _global_ variable context scope and doesn't
> allow overriding xsl:variables.
> OK, I will fix that :)
>
> Greetings,
> Greg
>
>
> 2013/6/20 gelo1234 
>
>>
>> Thank you! I will try to bring back Saxon :)
>>
>> Greetings,
>> Greg
>>
>>
>> This was discused before in the mailing list [1], it's a two step process
>>>
>>> * Add saxon dependency to pom file. [2]
>>>
>>> I think it's better to try Saxon directly if you used to work with it.
>>> Xalan is usually faster but as you have to migrate already made templates
>>> from Saxon IMO it's better to switch the engine.
>>>
>>> [1] http://mvnrepository.com/artifact/net.sf.saxon/Saxon-HE
>>> [2]
>>> http://cocoon.markmail.org/message/mjuftsfwdxmnc5fn?q=saxon#query:saxon+page:1+mid:fe2faygf7jdfrzb3+state:results
>>>
>>>
>>>
>>
>