Page 1 of 1

XQuery Documentation Generation Fails

Posted: Tue Oct 11, 2011 5:05 pm
by apmoh
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.
A sequence of more than one item is not allowed as the value in 'cast as' expression
I finally tracked it down to the fact that I overload functions. For example I have:

Code: Select all


declare function rng:xrng(param1) as item() {
stuff...
};

declare function rng:xrng(param1, param2) as item() {
stuff...
};
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

Re: XQuery Documentation Generation Fails

Posted: Wed Oct 12, 2011 6:05 pm
by adrian
Hello,

Could you please send us an email(support@oxygenxml.com) with a sample XQuery file that reproduces the minor problem(namespace)?

I've reproduced and logged to our issue tracking tool the other problem(overloaded function). We will update xqDoc in a future version of Oxygen and hopefully that will resolve the issue.

Regards,
Adrian

Re: XQuery Documentation Generation Fails

Posted: Mon Dec 05, 2011 7:10 pm
by apmoh
Hi,

Noticed that 13.1 is out, didn't see anything about xqDoc being updated. Can I assume that this didn't make the cut for this release, or is it that it is such a small change that it is not worth advertising?

Just curious,

Anthony

Re: XQuery Documentation Generation Fails

Posted: Tue Dec 06, 2011 11:37 am
by sorin_ristache
Hello,

xqDoc was not updated yet in Oxygen. We will probably update it in a future version and allow overloaded functions when generating the documentation. We will update this forum when we will have it ready.


Regards,
Sorin