Inspection Module
This XQuery Module contains functions for generating xqDoc files from XQuery modules.
Introduction
xqDoc provides a simple vendor neutral solution for generating a documentation from XQuery modules. The documentation conventions have been inspired by the JavaDoc standard. Documentation comments begin with (:~ and end with :), and tags start with @. xqDoc comments can be specified for main and library modules, variable declarations and function declarations, as shown in the following example:
(:~
: This module provides some sample functions to demonstrate
: the features of the XQDoc Module.
: @author BaseX Team
: @see http://docs.basex.org/wiki/XQDoc_Module
: @version 1.0
:)
module namespace samples = 'http://basex.org/modules/samples';
(:~ This is a sample number. :)
declare variable $samples:number := 1;
(:~
: This function simply returns the specified number.
: @param $number number to return
: @return specified number
:)
declare function samples:same($number as xs:integer) as xs:integer {
$number
};
Conventions
All functions in this module are assigned to the http://basex.org/modules/xqdoc namespace, which is statically bound to the xqdoc prefix.
All errors are assigned to the http://basex.org/errors namespace, which is statically bound to the bxerr prefix.
Functions
xqdoc:parse
| Signatures | xqdoc:parse($input as xs:string) as element(xqdoc:xqdoc)
|
| Summary | Parses the specified $input and generates an xqDoc element.
|
Changelog
This module was introduced with Version 7.7.