source: TI07-MOLES/trunk/eXist specific/xqueryLib/Utilities/utility_xquery_lib.xquery @ 2511

Subversion URL: http://proj.badc.rl.ac.uk/svn/ndg/TI07-MOLES/trunk/eXist specific/xqueryLib/Utilities/utility_xquery_lib.xquery@2511
Revision 2511, 610 bytes checked in by ko23, 12 years ago (diff)

Update voclib to include Roy's new IDs. Add version variable to libraries. Change ObsStn? xq to point at 375 deployment example

Line 
1module namespace utillib='http://ndg.nerc.ac.uk/xquery/lib/utilities';
2declare variable $utillib:libversion as xs:decimal {1.0};
3
4declare variable $utillib:moles_id_separator as xs:string {'__'};
5
6declare function utillib:strip-namespace($e as element()) as element()
7(: Removes namespace info from the element tree being addressed so that it will lie in the default namespace  :)
8{
9element {QName('', local-name($e))} 
10{
11let $parent :=$e
12let $childcount := count($parent/*)
13return
14if ($childcount>0) then
15for $child in ($e/*)
16return
17utillib:strip-namespace($child)
18else (data($e))
19}
20};
Note: See TracBrowser for help on using the repository browser.