On 25 June 2011 16:31, Christian GrĂ¼n wrote:
Hi,
we'd like to give you a preview on our upcoming EXPath Packaging API implementation, which will be released together with BaseX 6.7 next week: http://docs.basex.org/wiki/Packaging_API
Good news! Thanks for letting us know. This page is a good summary of what a package is and how to use it in BaseX.
If you are curious enough, feel free to try our latest stable snapshot: http://files.basex.org/releases/latest/
Two example archives are found at: http://files.basex.org/xar/
Your feedback is valuable to us.
Let's go then :-) First I want to say it seems to work pretty well as far as I've seen. I haven't tried the Java extension packaging though. A couple of things:
1/ If you want to install a package from the wild wild web, e.g. one of the packages at http://files.basex.org/xar/, it seems you have to download it to your local machine first. I would be convenient to support HTTP directly I guess (and would help to integrate with CXAN at a later stage ;-). And the error message returned now is a bit misleading; we get the message "Error: [PACK0001] Package 'http://files.basex.org/xar/functx-1.0.xar' does not exist." instead of something like "HTTP not supported".
2/ It seems the file name is required to ends with ".xar". I don't think this is a good idea to impose a restriction on the file names:
Command: REPO INSTALL ~/Downloads/functx-1.0.zip Error: [PACK0005] Package must be a .xar file.
3/ I tried a simple query using FunctX after having installed the package (yeah!) The strange thing is the example runs fine if I use the prefix functx, but not something else:
Query: import module namespace fx = "http://www.functx.com"; fx:substring-before-if-contains('blablabla', 'z') Error: [FONS0004] Namespace prefix not declared: "functx:Different_number_of_names".
Thank you for this good news, and good luck with the new release! Regards,