XQuery Documentation Generation Fails
Posted: Tue Oct 11, 2011 5:05 pm
Recently tried to take advantage of the Generate Documentation feature in the Tools menu for XQuery. Ran into two problems, one major, one minor.
Minor: The eXist database defines several built-in namespaces for extension functions, one of which is text:http://exist-db.org/xquery/text. Apparently, the parser sees the 'text' as a reserved word and assumes it is a text node constructor. By changing the prefix to 'txt' I was able to get past this problem.
Major: In attempting to generate documentation for a library module I kept getting the following error message.
Normally, I would accept that this is a limitation of the feature, and move on, except that the News section of the xqDoc site says that the new schema now supports overloaded functions. So I thought I'd bring this to your attention...
Thanks for a great product,
Anthony
Minor: The eXist database defines several built-in namespaces for extension functions, one of which is text:http://exist-db.org/xquery/text. Apparently, the parser sees the 'text' as a reserved word and assumes it is a text node constructor. By changing the prefix to 'txt' I was able to get past this problem.
Major: In attempting to generate documentation for a library module I kept getting the following error message.
I finally tracked it down to the fact that I overload functions. For example I have:A sequence of more than one item is not allowed as the value in 'cast as' expression
Code: Select all
declare function rng:xrng(param1) as item() {
stuff...
};
declare function rng:xrng(param1, param2) as item() {
stuff...
};
Thanks for a great product,
Anthony