Hi Florian, Sorry again for not providing you with an in-depth solution, but your code was not as self-contained as I was hoping, and it would take me some more time to find out why it was originally working in a previous version of BaseX. However, I checked your wrapper.xq file inside the archive, and I would recommend you to do the actual work in an extra Java function and limit the wrapper code to a single call of that function.
Maybe this helps? Christian On Fri, Jul 31, 2015 at 11:49 AM, Eckey, Florian <florian.ec...@adesso.de> wrote: > Hi Christian, > > Thanks for the hint. Here is a new link to the file: > https://drive.google.com/file/d/0Bw303eobkYo6a2kxVUExVlFQZ3M/view?usp=sharing. > Hope it works now. > Here some further input: > I want to integrate a vcard to xcard converter into basex. You can find some > java code on github, which is doing that: > https://github.com/mangstadt/ez-vcard. So what have done is create a xar > archive, which contains the java code and a xquery file which wraps the java > code. In version 7 of basex it works well if I declare the namespace and use > it. But in version 8.2.1 I get some problems. > Here is the code of xquery wrapper file: > > module namespace vcard="http://mycompany.de/util/vcards"; > > declare namespace ezv="java:ezvcard.Ezvcard"; > declare namespace pcts="java:ezvcard.Ezvcard$ParserChainTextString"; (: THIS > CANNOT BE FOUND :) > declare namespace pcxs="java:ezvcard.Ezvcard$ParserChainXmlString"; > declare namespace wcx="java:ezvcard.Ezvcard$WriterChainXml"; > declare namespace xcd="java:ezvcard.io.xml.XCardDocument"; > declare namespace jvcard="java:ezvcard.VCard"; > declare namespace vcv="java:ezvcard.VCardVersion"; > declare namespace vc="urn:ietf:params:xml:ns:vcard-4.0"; > > declare function vcard:vCards2xCards($vCards as xs:string) as > element(vc:vcards) > { > parse-xml(jvcard:writeXml(pcts:first(ezv:parse($vCards))))/* > }; > > The error is: java:ezvcard.Ezvcard$ParserChainTextString cannot be found. It > seams that basex in the newer version cannot access inner java classes. > Does anyone have an idea, why basex doesn't find it? > > Thanks and cheers > Florian > > -----Ursprüngliche Nachricht----- > Von: Christian Grün [mailto:christian.gr...@gmail.com] > Gesendet: Donnerstag, 30. Juli 2015 10:00 > An: Eckey, Florian <florian.ec...@adesso.de> > Cc: basex-talk@mailman.uni-konstanz.de > Betreff: Re: [basex-talk] BaseX Package and Jetty > > Hi Florian, > > Sorry for the late feedback. It seems I have no access to your file on Google > Drive. Maybe you can provide us with a mini code example, which only contains > the relevant files, and attach it to a mail to this list? > > Thanks in advance, > Christian > > > > On Tue, Jul 28, 2015 at 4:25 PM, Eckey, Florian <florian.ec...@adesso.de> > wrote: >> Hi guys, >> >> i have a problem with the basex package mechanism. I tried to install >> a self implemented xar file including java classes. In version 7 it >> works well, but in version 8.2.1 it doesn't. >> The xar can be found on: >> https://drive.google.com/open?id=0Bw303eobkYo6a2kxVUExVlFQZ3M. >> The java source code can be found on https://github.com/mangstadt/ez-vcard. >> With the newer basex version i get the error, that basex cannot find >> the inner java class "ezvcard.Ezvcard$ParserChainTextString". Does >> anyone have an idea, why basex doesn't find it? >> >> A further question: Is it planned to integrate the newest jetty >> version 9+ into basex to use HTTP/2 ? >> If not, is there a way to integrate it on my own? Do I have to replace >> the jetty classes only? >> >> Thanks and regards >> >> Florian >> >> -- >> Florian Eckey >> adesso AG T +49 231 930-9330 >> Software Developement F +49 231 930-9331 >> Stockholmer Allee 24 E florian.ec...@adesso.de >> 44269 Dortmund www.adesso.de >> >> --------------------------------------------------------- >> >>> business. people. technology. <<< >> --------------------------------------------------------- >> adesso AG mit Sitz in Dortmund >> Vorstand: Christoph Junge, Michael Kenfenheuer (Co-Vors.), Dr. Rüdiger >> Striemer (Co-Vors.) Vorsitzender des Aufsichtsrates: Prof. Dr. Volker >> Gruhn Amtsgericht Dortmund HRB 20663 >> >> ------------------------------------------------------- >> >>> business. people. technology. <<< >> ------------------------------------------------------- >> >> adesso AG mit Sitz in Dortmund >> Vorstand: Michael Kenfenheuer (Vors.), Christoph Junge, Andreas >> Prenneis Vorsitzender des Aufsichtsrates: Prof. Dr. Volker Gruhn >> Amtsgericht Dortmund HRB 20663 > > ------------------------------------------------------- > >>> business. people. technology. <<< > ------------------------------------------------------- > > adesso AG mit Sitz in Dortmund > Vorstand: Michael Kenfenheuer (Vors.), Christoph Junge, Andreas Prenneis > Vorsitzender des Aufsichtsrates: Prof. Dr. Volker Gruhn > Amtsgericht Dortmund HRB 20663