diff --git a/src/vue-poc/data/xquery.lib/basex-namespaces.xqy b/src/vue-poc/data/xquery.lib/basex-namespaces.xqy new file mode 100644 index 0000000..7e11369 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex-namespaces.xqy @@ -0,0 +1,95 @@ +xquery version "1.0"; +(:~ + : BaseX default static context. + : + : @see https://www.w3.org/TR/xquery/#id-basics + : @see https://www.w3.org/TR/xquery/#id-default-namespace + : @see http://docs.basex.org/wiki/Module_Library + :) + +declare default element namespace ""; +declare default function namespace "http://www.w3.org/2005/xpath-functions"; (: = 'fn:' :) + +(: XQuery 1.0 :) +declare namespace xml = "http://www.w3.org/XML/1998/namespace"; +declare namespace xs = "http://www.w3.org/2001/XMLSchema"; +declare namespace xsi = "http://www.w3.org/2001/XMLSchema-instance"; +declare namespace fn = "http://www.w3.org/2005/xpath-functions"; +declare namespace local = "http://www.w3.org/2005/xquery-local-functions"; + +(: XQuery 3.0 :) +declare namespace math = "http://www.w3.org/2005/xpath-functions/math"; + +(: XQuery 3.1 :) +declare namespace map = "http://www.w3.org/2005/xpath-functions/map"; +declare namespace array = "http://www.w3.org/2005/xpath-functions/array"; + +(: BaseX prior to 7.0 :) +declare namespace db = "http://basex.org/modules/db"; +declare namespace file = "http://expath.org/ns/file"; +declare namespace ft = "http://basex.org/modules/ft"; +declare namespace hof = "http://basex.org/modules/hof"; +declare namespace xslt = "http://basex.org/modules/xslt"; +declare namespace zip = "http://expath.org/ns/zip"; + +(: BaseX 7.0 :) +declare namespace crypto = "http://expath.org/ns/crypto"; +declare namespace json = "http://basex.org/modules/json"; +declare namespace sql = "http://basex.org/modules/sql"; + +(: BaseX 7.1 :) +declare namespace http = "http://expath.org/ns/http-client"; +declare namespace index = "http://basex.org/modules/index"; +declare namespace repo = "http://basex.org/modules/repo"; + +(: BaseX 7.3 :) +declare namespace archive = "http://basex.org/modules/archive"; +declare namespace client = "http://basex.org/modules/client"; +declare namespace convert = "http://basex.org/modules/convert"; +declare namespace hash = "http://basex.org/modules/hash"; +declare namespace out = "http://basex.org/modules/out"; +declare namespace proc = "http://basex.org/modules/proc"; +declare namespace prof = "http://basex.org/modules/prof"; +declare namespace validate = "http://basex.org/modules/validate"; +declare namespace xquery = "http://basex.org/modules/xquery"; + +(: BaseX 7.5 :) +declare namespace admin = "http://basex.org/modules/admin"; +declare namespace random = "http://basex.org/modules/random"; + +(: BaseX 7.6 :) +declare namespace fetch = "http://basex.org/modules/fetch"; +declare namespace html = "http://basex.org/modules/html"; + +(: BaseX 7.7 :) +declare namespace inspect = "http://basex.org/modules/inspect"; +declare namespace stream = "http://basex.org/modules/stream"; +declare namespace unit = "http://basex.org/modules/unit"; + +(: BaseX 7.7.2 :) +declare namespace csv = "http://basex.org/modules/csv"; + +(: BaseX 7.8 :) +declare namespace bin = "http://expath.org/ns/binary"; + +(: BaseX 8.0 :) +declare namespace user = "http://basex.org/modules/user"; + +(: BaseX 8.1 :) +declare namespace web = "http://basex.org/modules/web"; + +(: BaseX 8.3 :) +declare namespace strings = "http://basex.org/modules/strings"; + +(: BaseX 8.5 :) +declare namespace jobs = "http://basex.org/modules/jobs"; +declare namespace util = "http://basex.org/modules/util"; + +(: BaseX 9.0 :) +declare namespace lazy = "http://basex.org/modules/lazy"; +declare namespace update = "http://basex.org/modules/update"; + +(: BaseX 9.1 :) +declare namespace ws = "http://basex.org/modules/ws"; + +() \ No newline at end of file diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/admin.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/admin.xqy new file mode 100644 index 0000000..1567412 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/admin.xqy @@ -0,0 +1,22 @@ +xquery version "3.0"; +(:~ + : BaseX admin module functions + : + : @see http://docs.basex.org/wiki/Admin_Module + :) +module namespace admin = "http://basex.org/modules/admin#"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/7.5"; + +declare %a:since("basex", "7.5") function admin:sessions() as element(session)* external; +declare %a:since("basex", "7.5") function admin:logs() as element(file)* external; +declare %a:since("basex", "7.5") function admin:logs($date as xs:string) as element(entry)* external; +declare %a:since("basex", "7.8.2") function admin:logs($date as xs:string, $merge as xs:boolean) as element(entry)* external; +declare %a:since("basex", "8.0") function admin:write-log($text as xs:string) as empty-sequence() external; +declare %a:since("basex", "8.3") function admin:write-log($text as xs:string, $type as xs:string) as empty-sequence() external; +declare %a:since("basex", "8.2") function admin:delete-logs($date as xs:string) as empty-sequence() external; +declare %a:since("basex", "7.5") %a:until("basex", "8.0", "user:list-details#1") function admin:users() as element(user)* external; +declare %a:since("basex", "7.5") %a:until("basex", "8.0", "user:list-details#2") function admin:users($db as xs:string) as element(user)* external; diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/archive.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/archive.xqy new file mode 100644 index 0000000..c5babe8 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/archive.xqy @@ -0,0 +1,31 @@ +xquery version "3.1"; +(:~ + : BaseX archive module functions + : + : @see http://docs.basex.org/wiki/Archive_Module + :) +module namespace archive = "http://basex.org/modules/archive"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/7.3"; + +declare %a:since("basex", "7.3") function archive:create($entries as item(), $contents as item()*) as xs:base64Binary external; +declare %a:since("basex", "7.3") function archive:create($entries as item(), $contents as item()*, $options as map(*)?) as xs:base64Binary external; +declare %a:since("basex", "8.3") function archive:create-from($path as xs:string) as xs:base64Binary external; +declare %a:since("basex", "8.3") function archive:create-from($path as xs:string, $options as map(*)?) as xs:base64Binary external; +declare %a:since("basex", "8.3") function archive:create-from($path as xs:string, $options as map(*)?, $entries as item()*) as xs:base64Binary external; +declare %a:since("basex", "7.3") function archive:entries($archive as xs:base64Binary) as element(archive:entry)* external; +declare %a:since("basex", "7.3") function archive:options($archive as xs:base64Binary) (: as [7.3]element(archive:options) [8.5]map(*) :) external; +declare %a:since("basex", "7.3") function archive:extract-text($archive as xs:base64Binary) as xs:string* external; +declare %a:since("basex", "7.3") function archive:extract-text($archive as xs:base64Binary, $entries as item()*) as xs:string* external; +declare %a:since("basex", "7.3") function archive:extract-text($archive as xs:base64Binary, $entries as item()*, $encoding as xs:string) as xs:string* external; +declare %a:since("basex", "7.3") function archive:extract-binary($archive as xs:base64Binary) as xs:base64Binary* external; +declare %a:since("basex", "7.3") function archive:extract-binary($archive as xs:base64Binary, $entries as item()*) as xs:base64Binary* external; +declare %a:since("basex", "8.3") function archive:extract-to($path as xs:string, $archive as xs:base64Binary) as empty-sequence() external; +declare %a:since("basex", "8.3") function archive:extract-to($path as xs:string, $archive as xs:base64Binary, $entries as item()*) as empty-sequence() external; +declare %a:since("basex", "7.3") function archive:update($archive as xs:base64Binary, $entries as item()*, $contents as item()*) as xs:base64Binary external; +declare %a:since("basex", "7.3") function archive:delete($archive as xs:base64Binary, $entries as item()*) as xs:base64Binary external; +declare %a:since("basex", "7.7") %a:until("basex", "8.3", "archive:create-from#2", "archive:extract-to#1") function archive:write($path as xs:string, $archive as xs:base64Binary) as empty-sequence() external; +declare %a:since("basex", "7.7") %a:until("basex", "8.3", "archive:create-from#3", "archive:extract-to#2") function archive:write($path as xs:string, $archive as xs:base64Binary, $entries as item()*) as empty-sequence() external; diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/client.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/client.xqy new file mode 100644 index 0000000..ed2c030 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/client.xqy @@ -0,0 +1,19 @@ +xquery version "3.0"; +(:~ + : BaseX client module functions + : + : @see http://docs.basex.org/wiki/Client_Module + :) +module namespace client = "http://basex.org/modules/client"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/7.3"; + +declare %a:since("basex", "7.3") function client:connect($host as xs:string, $port as xs:integer, $user as xs:string, $password as xs:string) as xs:anyURI external; +declare %a:since("basex", "7.3") function client:execute($id as xs:anyURI, $command as xs:string) as xs:string external; +declare %a:since("basex", "7.5") function client:info($id as xs:anyURI) as xs:string external; +declare %a:since("basex", "7.3") function client:query($id as xs:anyURI, $query as xs:string) as item()* external; +declare %a:since("basex", "7.3") function client:query($id as xs:anyURI, $query as xs:string, $bindings (: as [7.3]map(*) [8.0]map(*)? :)) as item()* external; +declare %a:since("basex", "7.3") function client:close($id as xs:anyURI) as empty-sequence() external; diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/convert.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/convert.xqy new file mode 100644 index 0000000..87a7846 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/convert.xqy @@ -0,0 +1,32 @@ +xquery version "3.0"; +(:~ + : BaseX convert module functions + : + : @see http://docs.basex.org/wiki/Conversion_Module + :) +module namespace convert = "http://basex.org/modules/convert"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/7.3"; + +declare %a:since("basex", "7.3") function convert:binary-to-string($bytes as xs:anyAtomicType) as xs:string external; +declare %a:since("basex", "7.3") function convert:binary-to-string($bytes as xs:anyAtomicType, $encoding as xs:string) as xs:string external; +declare %a:since("basex", "8.5") function convert:binary-to-string($bytes as xs:anyAtomicType, $encoding as xs:string, $fallback as xs:boolean) as xs:string external; +declare %a:since("basex", "7.3") function convert:string-to-base64($string as xs:string) as xs:base64Binary external; +declare %a:since("basex", "7.3") function convert:string-to-base64($string as xs:string, $encoding as xs:string) as xs:base64Binary external; +declare %a:since("basex", "7.3") function convert:string-to-hex($string as xs:string) as xs:hexBinary external; +declare %a:since("basex", "7.3") function convert:string-to-hex($string as xs:string, $encoding as xs:string) as xs:hexBinary external; +declare %a:since("basex", "7.3") %a:until("basex", "9.0") %a:see-also("basex", "9.0", "convert:integers-to-base64") function convert:bytes-to-base64($input as xs:byte*) as xs:base64Binary (: $input as [7.3]xs:byte [8.7]xs:integer :) external; +declare %a:since("basex", "9.0") function convert:integers-to-base64($integers as xs:integer*) as xs:base64Binary external; +declare %a:since("basex", "7.3") %a:until("basex", "9.0") %a:see-also("basex", "9.0", "convert:integers-to-hex") function convert:bytes-to-hex($input as xs:integer*) as xs:hexBinary (: $input as [7.3]xs:byte [8.7]xs:integer :) external; +declare %a:since("basex", "7.3") function convert:integers-to-hex($integers as xs:integer*) as xs:hexBinary external; +declare %a:since("basex", "9.0") function convert:binary-to-integers($binary as xs:anyAtomicType) as xs:integer* external; +declare %a:since("basex", "7.3") function convert:binary-to-bytes($binary as xs:anyAtomicType) as xs:byte* external; +declare %a:since("basex", "7.3") function convert:integer-to-base($number as xs:integer, $base as xs:integer) as xs:string external; +declare %a:since("basex", "7.3") function convert:integer-from-base($string as xs:string, $base as xs:integer) as xs:integer external; +declare %a:since("basex", "7.5") function convert:integer-to-dateTime($milliseconds as xs:integer) as xs:dateTime external; +declare %a:since("basex", "7.5") function convert:dateTime-to-integer($dateTime as xs:dateTime) as xs:integer external; +declare %a:since("basex", "7.5") function convert:integer-to-dayTime($milliseconds as xs:integer) as xs:dayTimeDuration external; +declare %a:since("basex", "7.5") function convert:dayTime-to-integer($dayTime as xs:dayTimeDuration) as xs:integer external; \ No newline at end of file diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/csv.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/csv.xqy new file mode 100644 index 0000000..647b21e --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/csv.xqy @@ -0,0 +1,39 @@ +xquery version "3.1"; +(:~ + : BaseX CSV Module functions + : + : @see http://docs.basex.org/wiki/CSV_Module + :) +module namespace csv = "http://basex.org/modules/csv"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/7.7.2"; + +declare type csv-string = ( + %a:since("basex", "7.7.2") %a:until("basex", "9.1") for xs:string | + %a:since("basex", "9.1") for xs:string? +); + +declare type csv-result = ( + %a:since("basex", "7.7.2") %a:until("basex", "7.8") for element(csv) | + %a:since("basex", "7.8") %a:until("basex", "9.1") for document-node(element(csv)) | + %a:since("basex", "9.1") for item()? +); + +declare type csv-options = ( + %a:since("basex", "7.7.2") %a:until("basex", "8.2.1") for item() | + %a:since("basex", "8.2.1") %a:until("basex", "8.6.7") for map(xs:string, item()) | + %a:since("basex", "8.6.7") for map(*)? +); + +declare type csv-data = ( + %a:since("basex", "7.7.2") %a:until("basex", "8.6.7") for node() | + %a:since("basex", "8.6.7") for item()? +); + +declare %a:since("basex", "7.7.2") function csv:parse($string as csv-string) as csv-result external; +declare %a:since("basex", "7.7.2") function csv:parse($string as csv-string, $options as csv-options) as csv-result external; +declare %a:since("basex", "7.7.2") function csv:serialize($input as csv-data) as xs:string external; +declare %a:since("basex", "7.7.2") function csv:serialize($input as csv-data, $options as csv-options) as xs:string external; diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/db.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/db.xqy new file mode 100644 index 0000000..f66f570 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/db.xqy @@ -0,0 +1,76 @@ +xquery version "3.1"; +(:~ + : BaseX Database Module functions + : + : @see http://docs.basex.org/wiki/Database_Module + :) +module namespace db = "http://basex.org/modules/db"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/7.0"; (: NOTE: 7.0 is the earliest version definitions are available for. :) + +declare %a:since("basex", "7.0") function db:system() as element(system) external; +declare %a:since("basex", "9.0") function db:option($name as xs:string) as xs:string external; +declare %a:since("basex", "7.0") function db:info($db as xs:string) as element(database) external; +declare %a:since("basex", "8.6") function db:property($db as xs:string, $name as xs:string) as xs:anyAtomicType external; +declare %a:since("basex", "7.0") function db:list() as xs:string* external; +declare %a:since("basex", "7.0") function db:list($db as xs:string) as xs:string* external; +declare %a:since("basex", "7.0") function db:list($db as xs:string, $path as xs:string) as xs:string* external; +declare %a:since("basex", "7.1") function db:list-details() as element(database)* external; +declare %a:since("basex", "7.1") function db:list-details($db as xs:string) as element(resource)* external; +declare %a:since("basex", "7.1") function db:list-details($db as xs:string, $path as xs:string) as element(resource)* external; +declare %a:since("basex", "7.0") function db:backups() as element(backup)* external; +declare %a:since("basex", "7.0") function db:backups($db as xs:string) as element(backup)* external; +declare %a:since("basex", "7.0") function db:open($db as xs:string) as document-node()* external; +declare %a:since("basex", "7.0") function db:open($db as xs:string, $path as xs:string) as document-node()* external; +declare %a:since("basex", "7.0") function db:open-pre($db as xs:string, $pre as xs:integer) as node() external; +declare %a:since("basex", "7.0") function db:open-id($db as xs:string, $id as xs:integer) as node() external; +declare %a:since("basex", "7.0") function db:node-pre($nodes as node()*) as xs:integer* external; +declare %a:since("basex", "7.0") function db:node-id($nodes as node()*) as xs:integer* external; +declare %a:since("basex", "7.0") function db:retrieve($db as xs:string, $path as xs:string) as xs:base64Binary external; +declare %a:since("basex", "7.0") function db:retrieve($db as xs:string, $path as xs:string) as xs:base64Binary external; +declare %a:since("basex", "7.0") function db:text($db as xs:string, $strings as xs:string*) as text()* external; +declare %a:since("basex", "7.2.1") function db:text-range($db as xs:string, $min as xs:string, $max as xs:string) as text()* external; +declare %a:since("basex", "7.0") function db:attribute($db as xs:string, $strings as xs:string*) as attribute()* external; +declare %a:since("basex", "7.0") function db:attribute($db as xs:string, $strings as xs:strings*, $name as xs:string) as attribute()* external; +declare %a:since("basex", "7.2.1") function db:attribute-range($db as xs:string, $min as xs:string, $max as xs:string) as attribute()* external; +declare %a:since("basex", "7.0") function db:attribute-range($db as xs:string, $min as xs:string, $max as xs:string, $name as xs:string) as attribute()* external; +declare %a:since("basex", "8.4") function db:token($db as xs:string, $tokens as xs:string*) as attribute()* external; +declare %a:since("basex", "8.4") function db:token($db as xs:string, $tokens as xs:string*, $name as xs:string) as attribute()* external; +declare %a:since("basex", "7.5") function db:create($db as xs:string) as empty-sequence() external; +declare %a:since("basex", "7.5") function db:create($db as xs:string, $inputs as item()* (: $inputs [7.5] as item() [7.6] as item()* :)) as empty-sequence() external; +declare %a:since("basex", "7.5") function db:create($db as xs:string, $inputs as item()* (: $inputs [7.5] as item() [7.6] as item()*):), $paths as xs:string* (: $paths [7.5] as xs:string [7.6] as xs:string* :)) as empty-sequence() external; +declare %a:since("basex", "7.0") function db:create($db as xs:string, $inputs as item()* (: $inputs [7.5] as item() [7.6] as item()*):), $paths as xs:string* (: $paths [7.5] as xs:string [7.6] as xs:string* :), $options as map(*)? (: $options [7.7] as item() [8.2.1] as map(xs:string, xs:string) [8.2.3] as map(*) [8.6.7] as map(*)? :)) as empty-sequence() external; +declare %a:since("basex", "7.5") function db:drop($db as xs:string) as empty-sequence() external; +declare %a:since("basex", "7.0") function db:add($db as xs:string, $input as item() (: [7.5] :)) as empty-sequence() external; +declare %a:since("basex", "7.0") function db:add($db as xs:string, $input as item() (: [7.5] :), $path as xs:string) as empty-sequence() external; +declare %a:since("basex", "7.0") function db:add($db as xs:string, $input as item() (: [7.5] :), $path as xs:string, $options as map(*)? (: $options [7.9] as item() [8.2.1] as map(xs:string, xs:string) [8.2.3] as map(*) [8.6.7] as map(*)? :)) as empty-sequence() external; +declare %a:since("basex", "7.0") function db:delete($db as xs:string, $path as xs:string) as empty-sequence() external; +declare %a:since("basex", "7.8.2") function db:copy($db as xs:string, $name as xs:string) as empty-sequence() external; +declare %a:since("basex", "7.8.2") function db:alter($db as xs:string, $name as xs:string) as empty-sequence() external; +declare %a:since("basex", "7.8.2") function db:create-backup($db as xs:string) as empty-sequence() external; +declare %a:since("basex", "7.8.2") function db:drop-backup($name as xs:string) as empty-sequence() external; +declare %a:since("basex", "7.8.2") function db:restore($name as xs:string) as empty-sequence() external; +declare %a:since("basex", "7.0") function db:optimize($db as xs:string) as empty-sequence() external; +declare %a:since("basex", "7.0") function db:optimize($db as xs:string, $all as xs:boolean) as empty-sequence() external; +declare %a:since("basex", "7.0") function db:optimize($db as xs:string, $all as xs:boolean, $options as map(*)? (: $options [7.7] as item() [8.2.1] as map(xs:string, xs:string) [8.2.3] as map(*) [8.6.7] as map(*)? :)) as empty-sequence() external; +declare %a:since("basex", "7.0") function db:rename($db as xs:string, $source as xs:string, $target as xs:string) as empty-sequence() external; +declare %a:since("basex", "7.0") function db:replace($db as xs:string, $path as xs:string, $input as item()) as empty-sequence() external; +declare %a:since("basex", "7.0") function db:replace($db as xs:string, $path as xs:string, $input as item(), $options as map(*)? (: $options [7.9] as item() [8.2.1] as map(xs:string, xs:string) [8.2.3] as map(*) [8.6.7] as map(*)? :)) as empty-sequence() external; +declare %a:since("basex", "7.0") function db:store($db as xs:string, $path as xs:string, $input as item()) as empty-sequence() external; +declare %a:since("basex", "7.3") function db:flush($db as xs:string) as empty-sequence() external; +declare %a:since("basex", "7.7") function db:name($node as node()) as xs:string external; +declare %a:since("basex", "7.7") function db:path($node as node()) as xs:string external; +declare %a:since("basex", "7.0") function db:exists($db as xs:string) as xs:boolean external; +declare %a:since("basex", "7.0") function db:exists($db as xs:string, $path as xs:string) as xs:boolean external; +declare %a:since("basex", "7.0") function db:is-raw($db as xs:string, $path as xs:string) as xs:boolean external; +declare %a:since("basex", "7.0") function db:is-xml($db as xs:string, $path as xs:string) as xs:boolean external; +declare %a:since("basex", "7.1") function db:content-type($db as xs:string, $path as xs:string) as xs:string external; +declare %a:since("basex", "7.2.1") %a:until("basex", "9.0") %a:see-also("basex", "9.0", "update:output") function db:output() external; +declare %a:since("basex", "8.2") %a:until("basex", "9.0") %a:see-also("basex", "9.0", "update:cache") function db:output-cache() external; +declare %a:since("basex", "7.7") function db:export($db as xs:string, $path as xs:string) as empty-sequence() external; +declare %a:since("basex", "7.7") function db:export($db as xs:string, $path as xs:string, $params as item()) as empty-sequence() external; +declare %a:since("basex", "7.0") %a:until("basex", "8.2") function db:event($name as xs:string, $query as item()) as empty-sequence() external; +declare %a:since("basex", "7.0") %a:until("basex", "7.8") function db:fulltext($db as item(), $terms as xs:string) as text()* external; \ No newline at end of file diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/fetch.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/fetch.xqy new file mode 100644 index 0000000..d86db6f --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/fetch.xqy @@ -0,0 +1,22 @@ +xquery version "3.1"; +(:~ + : BaseX Fetch Module functions + : + : @see http://docs.basex.org/wiki/Fetch_Module + :) +module namespace fetch = "http://basex.org/modules/fetch"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/7.6"; + +declare %a:since("basex", "7.6") function fetch:binary($uri as xs:string) as xs:base64Binary external; +declare %a:since("basex", "7.6") function fetch:text($uri as xs:string) as xs:string external; +declare %a:since("basex", "7.6") function fetch:text($uri as xs:string, $encoding as xs:string) as xs:string external; +declare %a:since("basex", "8.5") function fetch:text($uri as xs:string, $encoding as xs:string, $fallback as xs:boolean) as xs:string external; +declare %a:since("basex", "8.0") function fetch:xml($uri as xs:string) as document-node() external; +declare %a:since("basex", "8.0") function fetch:xml($uri as xs:string, $options as map(*)? (: $options [8.0] as map(*) [8.6.7] as map(*)? :)) as document-node() external; +declare %a:since("basex", "9.0") function fetch:xml-binary($data as xs:base64Binary) as document-node() external; +declare %a:since("basex", "9.0") function fetch:xml-binary($data as xs:base64Binary, $options as map(*)?) as document-node() external; +declare %a:since("basex", "7.6") function fetch:content-type($uri as xs:string) as xs:string external; \ No newline at end of file diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/ft.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/ft.xqy new file mode 100644 index 0000000..e038d62 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/ft.xqy @@ -0,0 +1,35 @@ +xquery version "3.1"; +(:~ + : BaseX full-text functions + : + : @see http://docs.basex.org/Full-Text_Module + :) +module namespace ft = "http://basex.org/modules/ft"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/7.0"; (: NOTE: 7.0 is the earliest version definitions are available for. :) + +declare type ft-string = ( + %a:since("basex", "7.0") %a:until("basex", "9.1") for xs:string | + %a:since("basex", "9.1") for xs:string? +); + +declare %a:since("basex", "7.0") function ft:search($db as xs:string, $terms as item()*) as text()* external; +declare %a:since("basex", "7.2") function ft:search($db as xs:string, $terms as item()*, $options as map(*)?) as text()* external; +declare %a:since("basex", "7.8") function ft:contains($input as item()*, $terms as item()*) as xs:boolean external; +declare %a:since("basex", "7.8") function ft:contains($input as item()*, $terms as item()*, $options as map(*)?) as xs:boolean external; +declare %a:since("basex", "7.0") function ft:mark($nodes as node()*) as node()* external; +declare %a:since("basex", "7.0") function ft:mark($nodes as node()*, $name as xs:string) as node()* external; +declare %a:since("basex", "7.0") function ft:extract($nodes as node()*) as node()* external; +declare %a:since("basex", "7.0") function ft:extract($nodes as node()*, $name as xs:string) as node()* external; +declare %a:since("basex", "7.0") function ft:extract($nodes as node()*, $name as xs:string, $length as xs:integer) as node()* external; +declare %a:since("basex", "7.0") function ft:count($nodes as node()*) as xs:integer external; +declare %a:since("basex", "7.0") function ft:score($item as item()*) as xs:double* external; +declare %a:since("basex", "7.1") function ft:tokens($db as xs:string) as element(value)* external; +declare %a:since("basex", "7.1") function ft:tokens($db as xs:string, $prefix as xs:string) as element(value)* external; +declare %a:since("basex", "7.1") function ft:tokenize($string as ft-string) as xs:string* external; +declare %a:since("basex", "7.1") function ft:tokenize($string as ft-string, $options as map(*)?) as xs:string* external; +declare %a:since("basex", "8.0") function ft:normalize($string as ft-string) as xs:string external; +declare %a:since("basex", "8.0") function ft:normalize($string as ft-string, $options as map(*)?) as xs:string external; \ No newline at end of file diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/hash.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/hash.xqy new file mode 100644 index 0000000..34093b1 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/hash.xqy @@ -0,0 +1,17 @@ +xquery version "3.0"; +(:~ +: BaseX Hashing Module functions +: +: @see http://docs.basex.org/wiki/Hashing_Module +:) +module namespace hash = "http://basex.org/modules/hash"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/7.6"; + +declare %a:since("basex", "7.3") function hash:md5($value as xs:anyAtomicType) as xs:base64Binary external; +declare %a:since("basex", "7.3") function hash:sha1($value as xs:anyAtomicType) as xs:base64Binary external; +declare %a:since("basex", "7.3") function hash:sha256($value as xs:anyAtomicType) as xs:base64Binary external; +declare %a:since("basex", "7.3") function hash:hash($value as xs:anyAtomicType, $algorithm as xs:string) as xs:base64Binary external; \ No newline at end of file diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/hof.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/hof.xqy new file mode 100644 index 0000000..487a809 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/hof.xqy @@ -0,0 +1,22 @@ +xquery version "3.0"; +(:~ + : BaseX Higher Order Functions Module + : + : @see http://docs.basex.org/wiki/Higher-Order_Functions_Module + :) +module namespace hof = "http://basex.org/modules/hof"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/7.0"; + +declare %a:since("basex", "7.0") function hof:fold-left1($seq as item()+, $f as function(item()*, item()) as item()*) as item()* external; +declare %a:since("basex", "7.0") function hof:until($pred as function(item()*) as xs:boolean, $f as function(item()*) as item()*, $start as item()*) as item()* external; +declare %a:since("basex", "8.1") function hof:scan-left($seq as item()*, $start as item()*, $f as function(item()*, item()) as item()*) as item()* external; +declare %a:since("basex", "8.1") function hof:take-while($seq as item()*, $pred as function(item()) as xs:boolean) as item()* external; +declare %a:since("basex", "7.2") function hof:top-k-by($seq as item()*, $sort-key as function(item()) as item(), $k as xs:integer) as item()* external; +declare %a:since("basex", "7.2") function hof:top-k-with($seq as item()*, $lt as function(item(), item()) as xs:boolean, $k as xs:integer) as item()* external; +declare %a:since("basex", "7.0") function hof:id($expr as item()*) as item()* external; +declare %a:since("basex", "7.0") function hof:const($expr as item()*, $ignored as item()*) as item()* external; +declare %a:since("basex", "7.0") %a:until("basex", "7.2") function hof:iterate($f as function(item()*, item()*) as item()*, $seq as item()*) as item()* external; \ No newline at end of file diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/html.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/html.xqy new file mode 100644 index 0000000..14e88a2 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/html.xqy @@ -0,0 +1,16 @@ +xquery version "3.1"; +(:~ + : BaseX HTML Functions Module + : + : @see http://docs.basex.org/wiki/HTML_Module + :) +module namespace html = "http://basex.org/modules/html"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/7.6"; + +declare %a:since("basex", "7.6") function html:parser() as xs:string external; +declare %a:since("basex", "7.6") function html:parse($input as xs:anyAtomicType) as document-node() external; +declare %a:since("basex", "7.6") function html:parse($input as xs:anyAtomicType, $options as map(*)?) as document-node() external; \ No newline at end of file diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/index.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/index.xqy new file mode 100644 index 0000000..dae2458 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/index.xqy @@ -0,0 +1,24 @@ +xquery version "3.0"; +(:~ + : BaseX Index Module functions + : + : @see http://docs.basex.org/wiki/Index_Module + :) +module namespace index = "http://basex.org/modules/index"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/7.1"; + +declare %a:since("basex", "7.1") function index:facets($db as xs:string) as xs:string external; +declare %a:since("basex", "7.1") function index:facets($db as xs:string, $type as xs:string) as xs:string external; +declare %a:since("basex", "7.1") function index:texts($db as xs:string) as element(value)* external; +declare %a:since("basex", "7.1") function index:texts($db as xs:string, $prefix as xs:string) as element(value)* external; +declare %a:since("basex", "7.3") function index:texts($db as xs:string, $start as xs:string, $ascending as xs:boolean) as element(value)* external; +declare %a:since("basex", "7.1") function index:attributes($db as xs:string) as element(value)* external; +declare %a:since("basex", "7.3") function index:attributes($db as xs:string, $prefix as xs:string) as element(value)* external; +declare %a:since("basex", "7.1") function index:attributes($db as xs:string, $start as xs:string, $ascending as xs:boolean) as element(value)* external; +declare %a:since("basex", "8.4") function index:tokens($db as xs:string) as element(value)* external; +declare %a:since("basex", "7.1") function index:element-names($db as xs:string) as element(value)* external; +declare %a:since("basex", "7.1") function index:attribute-names($db as xs:string) as element(value)* external; \ No newline at end of file diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/inspect.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/inspect.xqy new file mode 100644 index 0000000..408fbd6 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/inspect.xqy @@ -0,0 +1,23 @@ +xquery version "3.1"; +(:~ + : BaseX Inspect Module functions + : + : @see http://docs.basex.org/wiki/Inspection_Module + :) +module namespace inspect = "http://basex.org/modules/inspect"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare namespace xqdoc = "http://www.xqdoc.org/1.0"; + +declare option o:requires "basex/7.7"; + +declare %a:since("basex", "7.7") function inspect:functions() as function(*)* external; +declare %a:since("basex", "7.7") function inspect:functions($uri as xs:string) as function(*)* external; +declare %a:since("basex", "8.5") function inspect:function-annotations($function as function(*)?) as map(xs:QName, xs:anyAtomicType*) external; +declare %a:since("basex", "8.5") function inspect:static-context($function as function(*)?, $name as xs:string) as item()* external; +declare %a:since("basex", "7.7") function inspect:function($function as function(*)) as element(function) external; +declare %a:since("basex", "7.7") function inspect:context() as element(context) external; +declare %a:since("basex", "7.7") function inspect:module($uri as xs:string) as element(module) external; +declare %a:since("basex", "7.7") function inspect:xqdoc($uri as xs:string) as element(xqdoc:xqdoc) external; diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/jobs.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/jobs.xqy new file mode 100644 index 0000000..f2ecb0d --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/jobs.xqy @@ -0,0 +1,28 @@ +xquery version "3.1"; +(:~ + : BaseX Jobs Module functions + : + : @see http://docs.basex.org/wiki/Jobs_Module + :) +module namespace jobs = "http://basex.org/modules/jobs"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/8.5"; + +declare %a:since("basex", "8.5") function jobs:current() as xs:string external; +declare %a:since("basex", "8.5") function jobs:list() as xs:string* external; +declare %a:since("basex", "8.5") function jobs:list-details() as element(job)* external; +declare %a:since("basex", "8.5") function jobs:list-details($id as xs:string) as element(job)* external; +declare %a:since("basex", "8.5") function jobs:finished($id as xs:string) as xs:boolean external; +declare %a:since("basex", "8.5") function jobs:services() as element(job)* external; +declare %a:since("basex", "8.5") function jobs:eval($query as xs:string) as xs:string external; +declare %a:since("basex", "8.5") function jobs:eval($query as xs:string, $bindings as map(*)?) as xs:string external; +declare %a:since("basex", "8.5") function jobs:eval($query as xs:string, $bindings as map(*)?, $options as map(*)?) as xs:string external; +declare %a:since("basex", "9.0") function jobs:invoke($uri as xs:string) as xs:string external; +declare %a:since("basex", "9.0") function jobs:invoke($uri as xs:string, $bindings as map(*)?) as xs:string external; +declare %a:since("basex", "9.0") function jobs:invoke($uri as xs:string, $bindings as map(*)?, $options as map(*)?) as xs:string external; +declare %a:since("basex", "8.5") function jobs:result($id as xs:string) as item()* external; +declare %a:since("basex", "8.5") function jobs:stop($id as xs:string) as empty-sequence() external; +declare %a:since("basex", "8.5") function jobs:wait($id as xs:string) as empty-sequence() external; diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/json.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/json.xqy new file mode 100644 index 0000000..a026b33 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/json.xqy @@ -0,0 +1,41 @@ +xquery version "3.1"; +(:~ + : BaseX JSON Module functions + : + : @see http://docs.basex.org/wiki/JSON_Module + :) +module namespace json = "http://basex.org/modules/json"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/7.0"; + +declare type json-string = ( + %a:since("basex", "7.0") %a:until("basex", "9.1") for xs:string | + %a:since("basex", "9.1") for xs:string? +); + +declare type json-options = ( + %a:since("basex", "7.7.2") %a:until("basex", "8.2.1") for item() | + %a:since("basex", "8.2.1") %a:until("basex", "8.2.3") for map(xs:string, xs:string) | + %a:since("basex", "8.2.3") %a:until("basex", "8.6.7") for map(*) | + %a:since("basex", "8.6.7") for map(*)? +); + +declare type json-result = ( + %a:since("basex", "7.0") %a:until("basex", "9.1") for element(json) | + %a:since("basex", "9.1") for item()? +); + +declare type json-result-item = ( + %a:since("basex", "7.7.2") %a:until("basex", "9.1") for item() | + %a:since("basex", "9.1") for item()? +); + +declare %a:since("basex", "7.0") function json:parse($string as json-string) as json-result external; +declare %a:since("basex", "7.7.2") function json:parse($string as json-string, $options as json-options) as json-result-item external; +declare %a:since("basex", "7.0") function json:serialize($input as item()?) as xs:string external; +declare %a:since("basex", "7.7.2") function json:serialize($input as item()?, $options as json-options) as xs:string external; +declare %a:since("basex", "7.0") %a:deprecated("basex", "7.7.2") function json:serialize-ml($input as node()) as xs:string external; +declare %a:since("basex", "7.0") %a:deprecated("basex", "7.7.2") function json:parse-ml($input as xs:string) as element() external; diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/lazy.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/lazy.xqy new file mode 100644 index 0000000..03e5e30 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/lazy.xqy @@ -0,0 +1,22 @@ +xquery version "3.0"; +(:~ + : BaseX Lazy Module functions + : + : @see http://docs.basex.org/wiki/Lazy_Module + :) +module namespace lazy = "http://basex.org/modules/lazy"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/9.0"; + +declare type cache-items = ( + %a:since("basex", "9.0") %a:until("basex", "9.1") for item() | + %a:since("basex", "9.1") for item()* +); + +declare %a:since("basex", "9.0") function lazy:cache($items as cache-items) as cache-items external; +declare %a:since("basex", "9.1") function lazy:cache($items as item()*, $lazy as xs:boolean) as item()* external; +declare %a:since("basex", "9.0") function lazy:is-lazy($item as item()) as xs:boolean external; +declare %a:since("basex", "9.0") function lazy:is-cached($item as item()) as xs:boolean external; \ No newline at end of file diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/out.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/out.xqy new file mode 100644 index 0000000..b5ae44e --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/out.xqy @@ -0,0 +1,17 @@ +xquery version "3.0"; +(:~ + : BaseX Output Module functions + : + : @see http://docs.basex.org/wiki/Output_Module + :) +module namespace out = "http://basex.org/modules/out"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/7.3"; + +declare %a:since("basex", "9.0") function out:cr() as xs:string external; +declare %a:since("basex", "7.3") function out:nl() as xs:string external; +declare %a:since("basex", "7.3") function out:tab() as xs:string external; +declare %a:since("basex", "7.3") function out:format($format as xs:string, $item1 as item(), $items as item()...) as xs:string external; diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/proc.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/proc.xqy new file mode 100644 index 0000000..c9e6711 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/proc.xqy @@ -0,0 +1,24 @@ +xquery version "3.1"; +(:~ + : BaseX Process Module functions + : + : @see http://docs.basex.org/wiki/Process_Module + :) +module namespace proc = "http://basex.org/modules/proc"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/7.3"; + +declare %a:since("basex", "7.3") function proc:system($cmd as xs:string) as xs:string external; +declare %a:since("basex", "7.3") function proc:system($cmd as xs:string, $args as xs:string*) as xs:string external; +declare %a:since("basex", "7.3") function proc:system($cmd as xs:string, $args as xs:string*, $options as map(xs:string, xs:string) (: $options [7.3] as xs:string [8.6] as map(xs:string, xs:string) :)) as xs:string external; +declare %a:since("basex", "7.3") function proc:execute($cmd as xs:string) as element(result) external; +declare %a:since("basex", "7.3") function proc:execute($cmd as xs:string, $args as xs:string*) as element(result) external; +declare %a:since("basex", "7.3") function proc:execute($cmd as xs:string, $args as xs:string*, $options as map(xs:string, xs:string) (: $options [7.3] as xs:string [8.6] as map(xs:string, xs:string) :)) as element(result) external; +declare %a:since("basex", "9.0") function proc:fork($cmd as xs:string) as element(result) external; +declare %a:since("basex", "9.0") function proc:fork($cmd as xs:string, $args as xs:string*) as element(result) external; +declare %a:since("basex", "9.0") function proc:fork($cmd as xs:string, $args as xs:string*, $options as map(xs:string, xs:string)) as element(result) external; +declare %a:since("basex", "8.3") function proc:property($name as xs:string) as xs:string? external; +declare %a:since("basex", "8.3") function proc:property-names() as xs:string* external; diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/prof.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/prof.xqy new file mode 100644 index 0000000..c58911e --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/prof.xqy @@ -0,0 +1,30 @@ +xquery version "3.1"; +(:~ + : BaseX Profiling Module functions + : + : @see http://docs.basex.org/wiki/Profiling_Module + :) +module namespace prof = "http://basex.org/modules/prof"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/7.3"; + +declare %a:since("basex", "9.0") function prof:track($expression as item()) as item()* external; +declare %a:since("basex", "9.0") function prof:track($expression as item(), $options as map(*)?) as item()* external; +declare %a:since("basex", "7.3") function prof:time($expr as item()) as item()* external; +declare %a:since("basex", "7.3") %a:until("basex", "9.0") function prof:time($expr as item(), $cache as xs:boolean) as item()* external; +declare %a:since("basex", "7.3") %a:until("basex", "9.0") function prof:time($expr as item(), $cache as xs:boolean, $label as xs:string) as item()* external; +declare %a:since("basex", "7.3") function prof:time($expr as item(), $label as xs:string) as item()* external; +declare %a:since("basex", "7.3") function prof:memory($expr as item()) as item()* external; +declare %a:since("basex", "7.3") function prof:memory($expr as item(), $label as xs:string) as item()* external; +declare %a:since("basex", "7.5") function prof:current-ms() as xs:integer external; +declare %a:since("basex", "7.5") function prof:current-ns() as xs:integer external; +declare %a:since("basex", "7.5") function prof:dump($expr as item()) as empty-sequence() external; +declare %a:since("basex", "7.5") function prof:dump($expr as item(), $label as xs:string) as empty-sequence() external; +declare %a:since("basex", "8.1") function prof:variables() as empty-sequence() external; +declare %a:since("basex", "8.5") function prof:type($expr as item()*) as item()* external; +declare %a:since("basex", "7.7") function prof:void($value as item()*) as empty-sequence() external; +declare %a:since("basex", "7.3") function prof:sleep($ms as xs:integer) as empty-sequence() external; +declare %a:since("basex", "7.6") function prof:human($number as xs:integer) as xs:string external; diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/random.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/random.xqy new file mode 100644 index 0000000..db8d222 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/random.xqy @@ -0,0 +1,22 @@ +xquery version "3.0"; +(:~ + : BaseX Random Module functions + : + : @see http://docs.basex.org/wiki/Random_Module + :) +module namespace random = "http://basex.org/modules/random"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/7.5"; + +declare %a:since("basex", "7.5") function random:double() as xs:double external; +declare %a:since("basex", "7.5") function random:integer() as xs:integer external; +declare %a:since("basex", "7.5") function random:integer($max as xs:integer) as xs:integer external; +declare %a:since("basex", "7.5") function random:seeded-double($seed as xs:integer, $num as xs:integer) as xs:double* external; +declare %a:since("basex", "7.5") function random:seeded-integer($seed as xs:integer, $num as xs:integer) as xs:integer* external; +declare %a:since("basex", "7.5") function random:seeded-integer($seed as xs:integer, $num as xs:integer, $max as xs:integer) as xs:integer* external; +declare %a:since("basex", "7.5") function random:gaussian($num as xs:integer) as xs:double* external; +declare %a:since("basex", "8.5") function random:seeded-permutation($seed as xs:integer, $items as item()*) as item()* external; +declare %a:since("basex", "7.5") function random:uuid() as xs:string external; \ No newline at end of file diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/repo.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/repo.xqy new file mode 100644 index 0000000..f180fe5 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/repo.xqy @@ -0,0 +1,16 @@ +xquery version "3.0"; +(:~ + : BaseX Repository Module functions + : + : @see http://docs.basex.org/wiki/Repository_Module + :) +module namespace repo = "http://basex.org/modules/repo"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/7.1"; + +declare %a:since("basex", "7.1") function repo:install($path as xs:string) as empty-sequence() external; +declare %a:since("basex", "7.1") function repo:delete($pkg as xs:string) as empty-sequence() external; +declare %a:since("basex", "7.1") function repo:list() as element(package)* (: [7.1] as xs:string [7.2] as element(package)* :) external; \ No newline at end of file diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/session.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/session.xqy new file mode 100644 index 0000000..29ce1dc --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/session.xqy @@ -0,0 +1,22 @@ +xquery version "3.0"; +(:~ + : BaseX Session Module functions + : + : @see http://docs.basex.org/wiki/Session_Module + :) +module namespace session = "http://basex.org/modules/session"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires-import "basex/7.5; location-uri=(none)"; + +declare %a:since("basex", "7.5") function session:id() as xs:string external; +declare %a:since("basex", "7.5") function session:created() as xs:dateTime external; +declare %a:since("basex", "7.5") function session:accessed() as xs:dateTime external; +declare %a:since("basex", "7.5") function session:names() as xs:string* external; +declare %a:since("basex", "7.5") function session:get($name as xs:string) as item()* (: [7.5] as xs:string? [7.9] as item()? [8.0] as item()* :) external; +declare %a:since("basex", "7.5") function session:get($name as xs:string, $default as item()* (: $default [7.5] as xs:string [8.0] as item()* :)) as item()* (: [7.5] as xs:string:) external; +declare %a:since("basex", "7.5") function session:set($name as xs:string, $value as item()* (: $value [7.5] as item() [8.0] as item()* :)) as empty-sequence() external; +declare %a:since("basex", "7.5") function session:delete($name as xs:string) as empty-sequence() external; +declare %a:since("basex", "7.5") function session:close() as empty-sequence() external; diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/sessions.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/sessions.xqy new file mode 100644 index 0000000..c6a30c6 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/sessions.xqy @@ -0,0 +1,22 @@ +xquery version "3.0"; +(:~ + : BaseX Sessions Module functions + : + : @see http://docs.basex.org/wiki/Sessions_Module + :) +module namespace sessions = "http://basex.org/modules/sessions"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires-import "basex/7.5; location-uri=(none)"; + +declare %a:since("basex", "7.5") function sessions:ids() as xs:string external; +declare %a:since("basex", "7.5") function sessions:created($id as xs:string) as xs:dateTime external; +declare %a:since("basex", "7.5") function sessions:accessed($id as xs:string) as xs:dateTime external; +declare %a:since("basex", "7.5") function sessions:names($id as xs:string) as xs:string* external; +declare %a:since("basex", "7.5") function sessions:get($id as xs:string, $name as xs:string) as item()* (: [7.5] as xs:string? [7.9] as item()? [8.0] as item()* :) external; +declare %a:since("basex", "7.5") function sessions:get($id as xs:string, $name as xs:string, $default as item()* (: $default [7.5] as xs:string [8.0] as item()* :)) as item()* (: [7.5] as xs:string:) external; +declare %a:since("basex", "7.5") function sessions:set($name as xs:string, $value as item()* (: $value [7.5] as item() [8.0] as item()* :)) as empty-sequence() external; +declare %a:since("basex", "7.5") function sessions:delete($name as xs:string) as empty-sequence() external; +declare %a:since("basex", "7.5") function sessions:close() as empty-sequence() external; diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/sql.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/sql.xqy new file mode 100644 index 0000000..71165a6 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/sql.xqy @@ -0,0 +1,25 @@ +xquery version "3.1"; +(:~ + : BaseX SQL Module functions + : + : @see http://docs.basex.org/wiki/SQL_Module + :) +module namespace sql = "http://basex.org/modules/sql"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/7.6"; + +declare %a:since("basex", "7.0") function sql:init($class as xs:string) as empty-sequence() external; +declare %a:since("basex", "7.0") function sql:connect($url as xs:string) as xs:anyURI (: [7.0] as xs:integer [9.0] as xs:anyURI :) external; +declare %a:since("basex", "7.0") function sql:connect($url as xs:string, $user as xs:string, $password as xs:string) as xs:anyURI (: [7.0] as xs:integer [9.0] as xs:anyURI :) external; +declare %a:since("basex", "7.0") function sql:connect($url as xs:string, $user as xs:string, $password as xs:string, $options as map(*)? (: $options [7.0] as item() [9.0] as map(*)? :)) as xs:anyURI (: [7.0] as xs:integer [9.0] as xs:anyURI :) external; +declare %a:since("basex", "7.0") function sql:execute($id as xs:anyURI, $statement as xs:string) as item()* (: [7.5] as element()* [8.7] as item()* :) external; +declare %a:since("basex", "9.0") function sql:execute($id as xs:anyURI, $statement as xs:string, $options as map(*)?) as item()* external; +declare %a:since("basex", "7.5") function sql:execute-prepared($id as xs:anyURI, $params as element(sql:parameters)) as item()* (: [7.5] as element()* [8.7] as item()* :) external; +declare %a:since("basex", "9.0") function sql:execute-prepared($id as xs:anyURI, $params as element(sql:parameters), $options as map(*)?) as item()* external; +declare %a:since("basex", "7.0") function sql:prepare($id as xs:anyURI, $statement as xs:string) as xs:anyURI (: [7.0] as xs:integer [9.0] as xs:anyURI :) external; +declare %a:since("basex", "7.0") function sql:commit($id as xs:anyURI) as empty-sequence() external; +declare %a:since("basex", "7.0") function sql:rollback($id as xs:anyURI) as empty-sequence() external; +declare %a:since("basex", "7.0") function sql:close($id as xs:anyURI) as empty-sequence() external; \ No newline at end of file diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/stream.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/stream.xqy new file mode 100644 index 0000000..f0f89a3 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/stream.xqy @@ -0,0 +1,17 @@ +xquery version "3.0"; +(:~ + : BaseX Stream Module functions + : + : @see http://docs.basex.org/wiki/Stream_Module + : @see http://docs.basex.org/wiki/Lazy_Module + :) +module namespace stream = "http://basex.org/modules/stream"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/7.7"; +declare option a:removed "basex/9.0"; + +declare %a:since("basex", "7.7") %a:until("basex", "9.0") function stream:materialize($value as item()*) as item()* external; +declare %a:since("basex", "7.7") %a:until("basex", "9.0") function stream:is-streamable($item as item()) as item() external; diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/strings.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/strings.xqy new file mode 100644 index 0000000..85ac74a --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/strings.xqy @@ -0,0 +1,16 @@ +xquery version "3.0"; +(:~ + : BaseX Strings Module functions + : + : @see http://docs.basex.org/wiki/Strings_Module + :) +module namespace strings = "http://basex.org/modules/strings"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/8.3"; + +declare %a:since("basex", "8.3") function strings:levenshtein($string1 as xs:string, $string2 as xs:string) as xs:double external; +declare %a:since("basex", "8.3") function strings:soundex($string as xs:string) as xs:string external; +declare %a:since("basex", "8.3") function strings:cologne-phonetic($string as xs:string) as xs:string external; \ No newline at end of file diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/unit.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/unit.xqy new file mode 100644 index 0000000..c447733 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/unit.xqy @@ -0,0 +1,33 @@ +xquery version "3.0"; +(:~ + : BaseX Unit Module functions + : + : @see http://docs.basex.org/wiki/Unit_Module + :) +module namespace unit = "http://basex.org/modules/unit"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/7.7"; + +declare %a:since("basex", "7.7") %a:annotation function unit:after() external; +declare %a:since("basex", "7.7") %a:annotation function unit:after($function as %parse-as("EQName") for xs:string) external; +declare %a:since("basex", "7.7") %a:annotation function unit:after-module() external; +declare %a:since("basex", "7.7") %a:annotation function unit:before() external; +declare %a:since("basex", "7.7") %a:annotation function unit:before($function as %parse-as("EQName") for xs:string) external; +declare %a:since("basex", "7.7") %a:annotation function unit:before-module() external; +declare %a:since("basex", "7.7") %a:annotation function unit:ignore() external; +declare %a:since("basex", "7.7") %a:annotation function unit:ignore($message as xs:string) external; +declare %a:since("basex", "7.7") %a:annotation function unit:test() external; +declare %a:since("basex", "7.7") %a:annotation function unit:test($error as xs:string, $code as %parse-as("EQName") for xs:string) external; + +declare %a:since("basex", "7.7") function unit:assert($test as item()*) as empty-sequence() external; +declare %a:since("basex", "7.7") function unit:assert($test as item()*, $info as item()) as empty-sequence() external; +declare %a:since("basex", "7.8") function unit:assert-equals($returned as item()*, $expected as item()*) as empty-sequence() external; +declare %a:since("basex", "7.8") function unit:assert-equals($returned as item()*, $expected as item()*, $info as item()) as empty-sequence() external; +declare %a:since("basex", "8.0") function unit:fail() as empty-sequence() external; +declare %a:since("basex", "7.7") function unit:fail($info as item()) as empty-sequence() external; +declare %a:since("basex", "7.7") %a:until("basex", "7.9") function unit:test() as element(testsuite)* external; +declare %a:since("basex", "7.7") %a:until("basex", "7.9") function unit:test($functions as function(*)*) as element(testsuite)* external; +declare %a:since("basex", "7.7") %a:until("basex", "7.9") function unit:test-uris($uris as xs:string*) as element(testsuites) external; \ No newline at end of file diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/update.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/update.xqy new file mode 100644 index 0000000..0333b62 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/update.xqy @@ -0,0 +1,20 @@ +xquery version "3.1"; +(:~ + : BaseX Update Module functions + : + : @see http://docs.basex.org/wiki/Update_Module + :) +module namespace update = "http://basex.org/modules/update"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/9.0"; + +declare %a:since("basex", "9.0") function update:apply($function as function(*), $arguments as array(*)) as empty-sequence() external; +declare %a:since("basex", "9.0") function update:for-each($seq as item()*, $function as function(item()) as item()*) as empty-sequence() external; +declare %a:since("basex", "9.0") function update:for-each-pair($seq1 as item()*, $function as function(item()) as item()*) as empty-sequence() external; +declare %a:since("basex", "9.0") function update:map-for-each($map as map(*), $function as function(xs:anyAtomicType, item()*) as item()*) as item()* external; +declare %a:since("basex", "9.0") function update:output($result as item()*) as empty-sequence() external; +declare %a:since("basex", "9.0") function update:cache() as item()* external; + diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/user.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/user.xqy new file mode 100644 index 0000000..681e07a --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/user.xqy @@ -0,0 +1,30 @@ +xquery version "3.0"; +(:~ + : BaseX User Module functions + : + : @see http://docs.basex.org/wiki/User_Module + :) +module namespace user = "http://basex.org/modules/user"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/8.0"; + +declare %a:since("basex", "8.1") function user:current() as xs:string external; +declare %a:since("basex", "8.0") function user:list() as xs:string* external; +declare %a:since("basex", "8.0") function user:list-details() as element(user)* external; +declare %a:since("basex", "8.0") function user:list-details($name as xs:string) as element(user)* external; +declare %a:since("basex", "8.0") function user:exists($name as xs:string) as xs:boolean external; +declare %a:since("basex", "8.6") function user:check($name as xs:string, $password as xs:string) as empty-sequence() external; +declare %a:since("basex", "8.6") function user:info() as element(info) external; +declare %a:since("basex", "8.0") function user:create($name as xs:string, $password as xs:string) as empty-sequence() external; +declare %a:since("basex", "8.0") function user:create($name as xs:string, $password as xs:string, $permissions as xs:string*) as empty-sequence() external; +declare %a:since("basex", "8.4") function user:create($name as xs:string, $password as xs:string, $permissions as xs:string*, $patterns as xs:string*) as empty-sequence() external; +declare %a:since("basex", "8.0") function user:grant($name as xs:string, $permissions as xs:string*) as empty-sequence() external; +declare %a:since("basex", "8.4") function user:grant($name as xs:string, $permissions as xs:string*, $patterns as xs:string*) as empty-sequence() external; +declare %a:since("basex", "8.0") function user:drop($name as xs:string) as empty-sequence() external; +declare %a:since("basex", "8.4") function user:drop($name as xs:string, $patterns as xs:string*) as empty-sequence() external; +declare %a:since("basex", "8.0") function user:alter($name as xs:string, $newname as xs:string) as empty-sequence() external; +declare %a:since("basex", "8.0") function user:password($name as xs:string, $password as xs:string) as empty-sequence() external; +declare %a:since("basex", "8.6") function user:update-info($info as element(info)) as empty-sequence() external; \ No newline at end of file diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/util.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/util.xqy new file mode 100644 index 0000000..694065c --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/util.xqy @@ -0,0 +1,20 @@ +xquery version "3.0"; +(:~ + : BaseX Utility Module functions + : + : @see http://docs.basex.org/wiki/Utility_Module + :) +module namespace util = "http://basex.org/modules/util"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/8.5"; + +declare %a:since("basex", "9.1") function util:if($condition as item()*, $then as item()*) as item()* external; +declare %a:since("basex", "9.1") function util:if($condition as item()*, $then as item()*, $else as item()*) as item()* external; +declare %a:since("basex", "9.1") function util:or($items as item()*, $default as item()*) as item()* external; +declare %a:since("basex", "8.5") function util:item-at($sequence as item()*, $position as xs:double) as item()? external; +declare %a:since("basex", "8.5") function util:item-range($sequence as item()*, $first as xs:double, $last as xs:double) as item()* external; +declare %a:since("basex", "8.5") function util:last-from($sequence as item()*) as item()? external; +declare %a:since("basex", "9.0") function util:replicate($sequence as item()*, $count as xs:integer) as item()* external; diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/validate.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/validate.xqy new file mode 100644 index 0000000..35bae64 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/validate.xqy @@ -0,0 +1,34 @@ +xquery version "3.0"; +(:~ + : BaseX Validate Module functions + : + : @see http://docs.basex.org/wiki/Validate_Module + :) +module namespace validate = "http://basex.org/modules/validate"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/7.3"; + +declare %a:since("basex", "7.3") function validate:dtd($input as item()) as empty-sequence() external; +declare %a:since("basex", "7.3") function validate:dtd($input as item(), $schema as xs:string?) as empty-sequence() external; +declare %a:since("basex", "7.6") function validate:dtd-info($input as item()) as xs:string* external; +declare %a:since("basex", "7.6") function validate:dtd-info($input as item(), $schema as xs:string?) as xs:string* external; +declare %a:since("basex", "8.3") function validate:dtd-report($input as item()) as element(report) external; +declare %a:since("basex", "8.3") function validate:dtd-report($input as item(), $schema as xs:string?) as element(report) external; +declare %a:since("basex", "7.3") function validate:xsd($input as item()) as empty-sequence() external; +declare %a:since("basex", "7.3") function validate:xsd($input as item(), $schema as item()?) as empty-sequence() external; +declare %a:since("basex", "7.3") function validate:xsd($input as item(), $schema as item()?, $version as xs:string) as empty-sequence() external; +declare %a:since("basex", "7.6") function validate:xsd-info($input as item()) as xs:string* external; +declare %a:since("basex", "7.6") function validate:xsd-info($input as item(), $schema as item()?) as xs:string* external; +declare %a:since("basex", "7.6") function validate:xsd-info($input as item(), $schema as item()?, $version as xs:string) as xs:string* external; +declare %a:since("basex", "8.3") function validate:xsd-report($input as item()) as element(report) external; +declare %a:since("basex", "8.3") function validate:xsd-report($input as item(), $schema as xs:string?) as element(report) external; +declare %a:since("basex", "8.3") function validate:xsd-report($input as item(), $schema as xs:string?, $version as xs:string) as element(report) external; +declare %a:since("basex", "8.3") function validate:rng($input as item(), $schema as item()) as empty-sequence() external; +declare %a:since("basex", "8.3") function validate:rng($input as item(), $schema as item(), $compact as xs:boolean) as empty-sequence() external; +declare %a:since("basex", "8.3") function validate:rng-info($input as item(), $schema as item()) as xs:string* external; +declare %a:since("basex", "8.3") function validate:rng-info($input as item(), $schema as item(), $compact as xs:boolean) as xs:string* external; +declare %a:since("basex", "8.3") function validate:rng-report($input as item(), $schema as xs:string) as element(report) external; +declare %a:since("basex", "8.3") function validate:rng-report($input as item(), $schema as xs:string, $compact as xs:boolean) as element(report) external; \ No newline at end of file diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/web.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/web.xqy new file mode 100644 index 0000000..15e8004 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/web.xqy @@ -0,0 +1,25 @@ +xquery version "3.1"; +(:~ + : BaseX Web Module functions + : + : @see http://docs.basex.org/wiki/Web_Module + :) +module namespace web = "http://basex.org/modules/web"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare namespace rest = "http://exquery.org/ns/restxq"; + +declare option o:requires "basex/8.1"; + +declare %a:since("basex", "8.1") function web:content-type($path as xs:string) as xs:string external; +declare %a:since("basex", "8.1") function web:create-url($url as xs:string, $parameters as map(*) (: [8.1] as map(*) [8.2] as map(item(), item()*) [9.0] as map(*) :)) as xs:string external; +declare %a:since("basex", "8.2") function web:encode-url($string as xs:string) as xs:string external; +declare %a:since("basex", "8.2") function web:decode-url($string as xs:string) as xs:string external; +declare %a:since("basex", "8.1") function web:redirect($location as xs:string) as element(rest:response) external; +declare %a:since("basex", "8.1") function web:redirect($location as xs:string, $parameters as map(*)) as element(rest:response) external; +declare %a:since("basex", "8.1") function web:response-header() as element(rest:response) external; +declare %a:since("basex", "8.1") function web:response-header($output as map(*)? (: [8.1] as map(*) [9.0] as map(*)? :)) as element(rest:response) external; +declare %a:since("basex", "8.1") function web:response-header($output as map(*)? (: [8.1] as map(*) [9.0] as map(*)? :), $headers as map(*)? (: [8.1] as map(*) [8.2] as map(xs:string, xs:string) [9.0] as map(*)? :)) as element(rest:response) external; +declare %a:since("basex", "9.0") function web:response-header($output as map(*)?, $headers as map(*)?, $atts as map(*)?) as element(rest:response) external; \ No newline at end of file diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/ws.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/ws.xqy new file mode 100644 index 0000000..d7f8798 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/ws.xqy @@ -0,0 +1,24 @@ +xquery version "3.1"; +(:~ + : BaseX WebSocket Module functions + : + : @see http://docs.basex.org/wiki/WebSocket_Module + :) +module namespace ws = "http://basex.org/modules/web"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/9.1"; + +declare %a:since("basex", "9.1") function ws:id() as xs:string external; +declare %a:since("basex", "9.1") function ws:ids() as xs:string* external; +declare %a:since("basex", "9.1") function ws:path($id as xs:string) as xs:string external; +declare %a:since("basex", "9.1") function ws:close($id as xs:string) as empty-sequence() external; +declare %a:since("basex", "9.1") function ws:send($message as item(), $ids as xs:string*) as empty-sequence() external; +declare %a:since("basex", "9.1") function ws:broadcast($message as xs:anyAtomicType) as empty-sequence() external; +declare %a:since("basex", "9.1") function ws:emit($message as xs:anyAtomicType) as empty-sequence() external; +declare %a:since("basex", "9.1") function ws:get($id as xs:string, $name as xs:string) as item()* external; +declare %a:since("basex", "9.1") function ws:get($id as xs:string, $name as xs:string, $default as item()*) as item()* external; +declare %a:since("basex", "9.1") function ws:set($id as xs:string, $name as xs:string, $value as item()*) as empty-sequence() external; +declare %a:since("basex", "9.1") function ws:delete($id as xs:string, $name as xs:string) as empty-sequence() external; \ No newline at end of file diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/xquery.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/xquery.xqy new file mode 100644 index 0000000..a35d820 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/xquery.xqy @@ -0,0 +1,33 @@ +xquery version "3.1"; +(:~ + : BaseX XQuery Module functions + : + : @see http://docs.basex.org/wiki/XQuery_Module + :) +module namespace xquery = "http://basex.org/modules/xquery"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/7.3"; + +declare %a:since("basex", "7.3") function xquery:eval($query as xs:string) as item()* external; +declare %a:since("basex", "7.3") function xquery:eval($query as xs:string, $bindings as map(*)?) as item()* external; +declare %a:since("basex", "7.8.2") function xquery:eval($query as xs:string, $bindings as map(*)?, $options as map(*)?) as item()* external; +declare %a:since("basex", "7.3") function xquery:eval-update($query as xs:string) as item()* external; +declare %a:since("basex", "7.3") function xquery:eval-update($query as xs:string, $bindings as map(*)?) as item()* external; +declare %a:since("basex", "7.8.2") function xquery:eval-update($query as xs:string, $bindings as map(*)?, $options as map(*)?) as item() external; +declare %a:since("basex", "7.3") function xquery:invoke($uri as xs:string) as item()* external; +declare %a:since("basex", "7.3") function xquery:invoke($uri as xs:string, $bindings as map(*)?) as item()* external; +declare %a:since("basex", "7.3") function xquery:invoke($uri as xs:string, $bindings as map(*)?, $options as map(*)?) as item()* external; +declare %a:since("basex", "9.0") function xquery:invoke-update($uri as xs:string) as item()* external; +declare %a:since("basex", "9.0") function xquery:invoke-update($uri as xs:string, $bindings as map(*)?) as item()* external; +declare %a:since("basex", "9.0") function xquery:invoke-update($uri as xs:string, $bindings as map(*)?, $options as map(*)?) as item()* external; +declare %a:since("basex", "8.0") function xquery:parse($query as xs:string) as item()? external; +declare %a:since("basex", "8.0") function xquery:parse($query as xs:string, $options as map(*)?) as item()? external; +declare %a:since("basex", "7.3") function xquery:parse-uri($uri as xs:string) as item()? external; +declare %a:since("basex", "7.3") function xquery:parse-uri($uri as xs:string, $options as map(*)?) as item()? external; +declare %a:since("basex", "8.5") function xquery:fork-join($functions as function(*)*) as item()* external; +declare %a:since("basex", "7.8") %a:until("basex", "8.0") function xquery:evaluate() as item()* external; +declare %a:since("basex", "7.3") %a:until("basex", "8.5") %a:see-also("basex", "8.5", "prof:type") function xquery:type() as item()* external; +declare %a:since("basex", "8.0") %a:until("basex", "9.0") %a:see-also("basex", "9.0", "xquery:eval-update") function xquery:update() as item()* external; diff --git a/src/vue-poc/data/xquery.lib/basex.org/modules/xslt.xqy b/src/vue-poc/data/xquery.lib/basex.org/modules/xslt.xqy new file mode 100644 index 0000000..6763905 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/basex.org/modules/xslt.xqy @@ -0,0 +1,24 @@ +xquery version "3.1"; +(:~ + : BaseX XSLT Module functions + : + : @see http://docs.basex.org/wiki/XSLT_Module + :) +module namespace xslt = "http://basex.org/modules/xslt"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "basex/7.0"; (: NOTE: 7.0 is the earliest version definitions are available for. :) + +declare %a:since("basex", "7.0") %a:until("basex", "7.3", "xslt:processor#0") variable $xslt:processor external; +declare %a:since("basex", "7.0") %a:until("basex", "7.3", "xslt:version#0") variable $xslt:version external; + +declare %a:since("basex", "7.3") function xslt:processor() as xs:string external; +declare %a:since("basex", "7.3") function xslt:version() as xs:string external; +declare %a:since("basex", "7.0") function xslt:transform($input as item(), $stylesheet as item()) as node() external; +declare %a:since("basex", "7.0") function xslt:transform($input as item(), $stylesheet as item(), $params as map(*)? (: $params [7.0] as map(xs:string, xs:string) [9.0] as map(*)? :)) as node() external; +declare %a:since("basex", "9.0") function xslt:transform($input as item(), $stylesheet as item(), $params as map(*)?, $options as map(*)?) as node() external; +declare %a:since("basex", "7.6") function xslt:transform-text($input as item(), $stylesheet as item()) as xs:string external; +declare %a:since("basex", "7.6") function xslt:transform-text($input as item(), $stylesheet as item(), $params as map(*)? (: $params [7.6] as map(xs:string, xs:string) [9.0] as map(*)? :) ) as xs:string external; +declare %a:since("basex", "9.0") function xslt:transform-text($input as item(), $stylesheet as item(), $params as map(*)?, $options as map(*)?) as xs:string external; \ No newline at end of file diff --git a/src/vue-poc/data/xquery.lib/expath.org/ns/binary.xqy b/src/vue-poc/data/xquery.lib/expath.org/ns/binary.xqy new file mode 100644 index 0000000..c897d15 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/expath.org/ns/binary.xqy @@ -0,0 +1,58 @@ +xquery version "3.0"; +(:~ + : Binary Module 1.0 (EXPath Module 3 December 2013) + : + : @see http://expath.org/spec/binary/1.0 + : @see http://docs.basex.org/wiki/Binary_Module + :) +module namespace bin = "http://expath.org/ns/binary"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "expath-binary/1.0"; + +declare option o:implements-module "basex/7.8 as expath-binary/1.0-20131203"; + +declare option o:implements-module "saxon/pe/9.6 as expath-binary/1.0-20131203"; +declare option o:implements-module "saxon/ee/9.6 as expath-binary/1.0-20131203"; + +declare %a:since("expath-binary", "1.0-20131203") function bin:hex($in as xs:string?) as xs:base64Binary? external; +declare %a:since("expath-binary", "1.0-20131203") function bin:bin($in as xs:string?) as xs:base64Binary? external; +declare %a:since("expath-binary", "1.0-20131203") function bin:octal($in as xs:string?) as xs:base64Binary? external; +declare %a:since("expath-binary", "1.0-20131203") function bin:to-octets($in as xs:base64Binary) as xs:integer* external; +declare %a:since("expath-binary", "1.0-20131203") function bin:from-octets($in as xs:integer*) as xs:base64Binary external; +declare %a:since("expath-binary", "1.0-20131203") function bin:length($in as xs:base64Binary) as xs:integer external; +declare %a:since("expath-binary", "1.0-20131203") function bin:part($in as xs:base64Binary?, $offset as xs:integer) as xs:base64Binary? external; +declare %a:since("expath-binary", "1.0-20131203") function bin:part($in as xs:base64Binary?, $offset as xs:integer, $size as xs:integer) as xs:base64Binary? external; +declare %a:since("expath-binary", "1.0-20131203") function bin:join($in as xs:base64Binary*) as xs:base64Binary external; +declare %a:since("expath-binary", "1.0-20131203") function bin:insert-before($in as xs:base64Binary?, $offset as xs:integer, $extra as xs:base64Binary?) as xs:base64Binary external; +declare %a:since("expath-binary", "1.0-20131203") function bin:pad-left($in as xs:base64Binary?, $size as xs:integer) as xs:base64Binary? external; +declare %a:since("expath-binary", "1.0-20131203") function bin:pad-left($in as xs:base64Binary?, $size as xs:integer, $octect as xs:integer) as xs:base64Binary? external; +declare %a:since("expath-binary", "1.0-20131203") function bin:pad-right($in as xs:base64Binary?, $size as xs:integer) as xs:base64Binary? external; +declare %a:since("expath-binary", "1.0-20131203") function bin:pad-right($in as xs:base64Binary?, $size as xs:integer, $octect as xs:integer) as xs:base64Binary? external; +declare %a:since("expath-binary", "1.0-20131203") function bin:find($in as xs:base64Binary?, $offset as xs:integer, $search as xs:base64Binary) as xs:integer? external; +declare %a:since("expath-binary", "1.0-20131203") function bin:decode-string($in as xs:base64Binary?, $encoding as xs:string) as xs:string? external; +declare %a:since("expath-binary", "1.0-20131203") function bin:decode-string($in as xs:base64Binary?, $encoding as xs:string, $offset as xs:integer) as xs:string? external; +declare %a:since("expath-binary", "1.0-20131203") function bin:decode-string($in as xs:base64Binary?, $encoding as xs:string, $offset as xs:integer, $size as xs:integer) as xs:string? external; +declare %a:since("expath-binary", "1.0-20131203") %a:missing("basex", "7.8") function bin:encode-string($in as xs:string?) as xs:base64Binary? external; +declare %a:since("expath-binary", "1.0-20131203") function bin:encode-string($in as xs:string?, $encoding as xs:string) as xs:base64Binary? external; +declare %a:since("expath-binary", "1.0-20131203") function bin:pack-double($in as xs:double) as xs:base64Binary external; +declare %a:since("expath-binary", "1.0-20131203") function bin:pack-double($in as xs:double, $octet-order as xs:string) as xs:base64Binary external; +declare %a:since("expath-binary", "1.0-20131203") function bin:pack-float($in as xs:float) as xs:base64Binary external; +declare %a:since("expath-binary", "1.0-20131203") function bin:pack-float($in as xs:float, $octet-order as xs:string) as xs:base64Binary external; +declare %a:since("expath-binary", "1.0-20131203") function bin:pack-integer($in as xs:integer, $size as xs:integer) as xs:base64Binary external; +declare %a:since("expath-binary", "1.0-20131203") function bin:pack-integer($in as xs:integer, $size as xs:integer, $octet-order as xs:string) as xs:base64Binary external; +declare %a:since("expath-binary", "1.0-20131203") function bin:unpack-double($in as xs:base64Binary, $offset as xs:integer) as xs:double external; +declare %a:since("expath-binary", "1.0-20131203") function bin:unpack-double($in as xs:base64Binary, $offset as xs:integer, $octet-order as xs:string) as xs:double external; +declare %a:since("expath-binary", "1.0-20131203") function bin:unpack-float($in as xs:base64Binary, $offset as xs:integer) as xs:float external; +declare %a:since("expath-binary", "1.0-20131203") function bin:unpack-float($in as xs:base64Binary, $offset as xs:integer, $octet-order as xs:string) as xs:float external; +declare %a:since("expath-binary", "1.0-20131203") function bin:unpack-integer($in as xs:base64Binary, $offset as xs:integer, $size as xs:integer) as xs:integer external; +declare %a:since("expath-binary", "1.0-20131203") function bin:unpack-integer($in as xs:base64Binary, $offset as xs:integer, $size as xs:integer, $octet-order as xs:string) as xs:integer external; +declare %a:since("expath-binary", "1.0-20131203") function bin:unpack-unsigned-integer($in as xs:base64Binary, $offset as xs:integer, $size as xs:integer) as xs:integer external; +declare %a:since("expath-binary", "1.0-20131203") function bin:unpack-unsigned-integer($in as xs:base64Binary, $offset as xs:integer, $size as xs:integer, $octet-order as xs:string) as xs:integer external; +declare %a:since("expath-binary", "1.0-20131203") function bin:or($a as xs:base64Binary?, $b as xs:base64Binary?) as xs:base64Binary? external; +declare %a:since("expath-binary", "1.0-20131203") function bin:xor($a as xs:base64Binary?, $b as xs:base64Binary?) as xs:base64Binary? external; +declare %a:since("expath-binary", "1.0-20131203") function bin:and($a as xs:base64Binary?, $b as xs:base64Binary?) as xs:base64Binary? external; +declare %a:since("expath-binary", "1.0-20131203") function bin:not($in as xs:base64Binary?) as xs:base64Binary? external; +declare %a:since("expath-binary", "1.0-20131203") function bin:shift($in as xs:base64Binary?, $by as xs:integer) as xs:base64Binary? external; diff --git a/src/vue-poc/data/xquery.lib/expath.org/ns/crypto.xqy b/src/vue-poc/data/xquery.lib/expath.org/ns/crypto.xqy new file mode 100644 index 0000000..991d3ef --- /dev/null +++ b/src/vue-poc/data/xquery.lib/expath.org/ns/crypto.xqy @@ -0,0 +1,30 @@ +xquery version "3.0"; +(:~ + : Cryptographic Module (EXPath Candidate Module 14 February 2015) + : + : @see https://web.archive.org/web/20170227073403/http://expath.org/spec/crypto/20150214 + : @see https://web.archive.org/web/20170227144046/http://expath.org/spec/crypto/20110810 + : @see http://docs.basex.org/wiki/Crypto_Module + :) +module namespace crypto = "http://expath.org/ns/crypto"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "expath-crypto/1.0-20110810"; + +declare option o:implements-module "basex/7.0 as expath-crypto/1.0-20110810"; + +declare type hmac-key = ( + %a:since("expath-crypto", "1.0-20110810") %a:until("basex", "8.6") for xs:string | + %a:since("basex", "8.6") for xs:anyAtomicType (: = (xs:string | xs:hexBinary | xs:base64Binary) :) +); + +declare %a:since("expath-crypto", "1.0-20110810") function crypto:hmac($message as xs:string, $key as hmac-key, $algorithm as xs:string) as xs:base64Binary external; +declare %a:since("expath-crypto", "1.0-20110810") function crypto:hmac($message as xs:string, $key as hmac-key, $algorithm as xs:string, $encoding as xs:string) as xs:base64Binary external; +declare %a:since("expath-crypto", "1.0-20110810") function crypto:encrypt($input as xs:string, $encoding as xs:string, $key as xs:string, $algorithm as xs:string) as xs:string external; +declare %a:since("expath-crypto", "1.0-20110810") function crypto:decrypt($input as xs:string, $type as xs:string, $key as xs:string, $algorithm as xs:string) as xs:string external; +declare %a:since("expath-crypto", "1.0-20110810") function crypto:generate-signature($input as node(), $canonicalization as xs:string, $digest as xs:string, $signature as xs:string, $prefix as xs:string, $type as xs:string) as node() external; +declare %a:since("expath-crypto", "1.0-20110810") function crypto:generate-signature($input as node(), $canonicalization as xs:string, $digest as xs:string, $signature as xs:string, $prefix as xs:string, $type as xs:string, $xpath as xs:string, $certificate as node()) as node() external; +declare %a:since("expath-crypto", "1.0-20110810") function crypto:generate-signature($input as node(), $canonicalization as xs:string, $digest as xs:string, $signature as xs:string, $prefix as xs:string, $type as xs:string, $xpath-or-certificate as item() (: = (xs:string | node()) :)) as node() external; +declare %a:since("expath-crypto", "1.0-20110810") function crypto:validate-signature($input-doc as node()) as xs:boolean external; \ No newline at end of file diff --git a/src/vue-poc/data/xquery.lib/expath.org/ns/file.xqy b/src/vue-poc/data/xquery.lib/expath.org/ns/file.xqy new file mode 100644 index 0000000..0707cd5 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/expath.org/ns/file.xqy @@ -0,0 +1,129 @@ +xquery version "3.0"; +(:~ + : File Module 1.0 (EXPath Module 20 February 2015) + : + : @see http://expath.org/spec/file/1.0 + : @see http://docs.basex.org/wiki/File_Module + :) +module namespace file = "http://expath.org/ns/file"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare namespace output = "http://www.w3.org/2010/xslt-xquery-serialization"; + +declare option o:requires "expath-file/1.0-20100517"; + +declare option o:implements-module "basex/7.0 as expath-file/1.0-20100517"; (: NOTE: 7.0 is the earliest version definitions are available for. :) +declare option o:implements-module "basex/7.3 as expath-file/1.0-20120614"; +declare option o:implements-module "basex/7.8 as expath-file/1.0-20131203"; +declare option o:implements-module "basex/8.0 as expath-file/1.0-20150220"; + +declare option o:implements-module "saxon/pe/9.5 as expath-file/1.0-20150220"; (: TODO: Map saxon versions to the correct file versions. :) +declare option o:implements-module "saxon/ee/9.5 as expath-file/1.0-20150220"; (: TODO: Map saxon versions to the correct file versions. :) + +declare type append-params = ( + %a:since("expath-file", "1.0-20120614") for element(output:serialization-parameters) | + %a:since("basex", "7.0") for item() +); + +declare type copy-write-result = ( + %a:since("expath-file", "1.0-20100517") %a:until("expath-file", "1.0-20120614") for xs:boolean | + %a:since("expath-file", "1.0-20120614") %a:since("basex", "7.0") for empty-sequence() +); + +declare type path-uri-result = ( + %a:since("expath-file", "1.0-20100517") for xs:anyURI | + %a:since("basex", "7.0") for xs:string +); + +declare type write-params = ( + %a:since("expath-file", "1.0-20100517") for node()* | + %a:since("basex", "7.0") for item() +); + +declare type any-binary-type = ( + %a:since("expath-file", "1.0-20120614") for xs:base64Binary | + %a:since("basex", "7.0") for (xs:base64Binary | xs:hexBinary) +); + +declare %a:since("basex", "7.0") %a:until("basex", "7.3", "file:dir-separator#0") variable $file:directory-separator external; +declare %a:since("basex", "7.0") %a:until("basex", "7.3", "file:path-separator#0") variable $file:path-separator external; + +declare %a:since("expath-file", "1.0-20120614") %a:since("basex", "7.0") function file:append($path as xs:string, $items as item()*) as empty-sequence() external; +declare %a:since("expath-file", "1.0-20120614") %a:since("basex", "7.0") function file:append($path as xs:string, $items as item()*, $params as append-params) as empty-sequence() external; +declare %a:since("expath-file", "1.0-20120614") %a:since("basex", "7.0") function file:append-binary($path as xs:string, $value as any-binary-type) as empty-sequence() external; +declare %a:since("expath-file", "1.0-20120614") function file:append-text($path as xs:string, $value as xs:string) as empty-sequence() external; +declare %a:since("expath-file", "1.0-20120614") function file:append-text($path as xs:string, $value as xs:string, $encoding as xs:string) as empty-sequence() external; +declare %a:since("expath-file", "1.0-20120614") function file:append-text-lines($path as xs:string, $values as xs:string*) as empty-sequence() external; +declare %a:since("expath-file", "1.0-20120614") function file:append-text-lines($path as xs:string, $values as xs:string*, $encoding as xs:string) as empty-sequence() external; +declare %a:until("expath-file", "1.0-20150220") function file:base-dir() as xs:string? external; +declare %a:since("expath-file", "1.0-20120614") %a:since("basex", "7.0") %a:since("expath-file", "1.0-20131203", "file:name#1") %a:until("basex", "7.8", "file:name#1") function file:base-name($path as xs:string) as xs:string external; +declare %a:since("expath-file", "1.0-20120614") %a:since("basex", "7.0") %a:since("expath-file", "1.0-20131203") %a:until("basex", "7.8") function file:base-name($path as xs:string, $suffix as xs:string) as xs:string external; +declare %a:until("expath-file", "1.0-20150220") function file:children($dir as xs:string) as xs:string* external; +declare %a:since("expath-file", "1.0-20100517") function file:copy($source as xs:string, $destination as xs:string) as copy-write-result external; +declare %a:since("expath-file", "1.0-20100517") %a:until("expath-file", "1.0-20120614") %a:missing("basex", "7.0") function file:copy($source as xs:string, $destination as xs:string, $overwrite as xs:boolean) as xs:boolean external; +declare %a:since("expath-file", "1.0-20120614") function file:create-dir($dir as xs:string) as empty-sequence() external; +declare %a:since("basex", "7.0") %a:until("basex", "7.3", "file:create-dir#1") function file:create-directory($dir as xs:string) as xs:boolean external; +declare %a:since("expath-file", "1.0-20131203") %a:since("basex", "7.7") function file:create-temp-dir($prefix as xs:string, $suffix as xs:string) as xs:string external; +declare %a:since("expath-file", "1.0-20131203") %a:since("basex", "7.7") function file:create-temp-dir($prefix as xs:string, $suffix as xs:string, $dir as xs:string) as xs:string external; +declare %a:since("expath-file", "1.0-20131203") %a:since("basex", "7.7") function file:create-temp-file($prefix as xs:string, $suffix as xs:string) as xs:string external; +declare %a:since("expath-file", "1.0-20131203") %a:since("basex", "7.7") function file:create-temp-file($prefix as xs:string, $suffix as xs:string, $dir as xs:string) as xs:string external; +declare %a:until("expath-file", "1.0-20150220") function file:current-dir() as xs:string external; +declare %a:since("expath-file", "1.0-20120614") %a:since("basex", "7.0") function file:delete($path as xs:string) as empty-sequence() external; +declare %a:since("expath-file", "1.0-20120614") %a:since("basex", "7.2.1") function file:delete($path as xs:string, $recursive as xs:boolean) as empty-sequence() external; +declare %a:since("expath-file", "1.0-20120614") %a:since("basex", "7.0") %a:until("expath-file", "1.0-20131203", "file:parent#1") %a:until("basex", "7.8", "file:parent#1") function file:dir-name($path as xs:string) as xs:string external; +declare %a:since("expath-file", "1.0-20120614") %a:since("basex", "7.0") function file:dir-separator() as xs:string external; +declare %a:since("expath-file", "1.0-20100517") function file:exists($path as xs:string) as xs:boolean external; +declare %a:since("expath-file", "1.0-20100517") %a:until("expath-file", "1.0-20120614") %a:missing("basex", "7.0") function file:files($path as xs:string) as xs:string* external; +declare %a:since("expath-file", "1.0-20100517") %a:until("expath-file", "1.0-20120614") %a:missing("basex", "7.0") function file:files($path as xs:string, $pattern as xs:string) as xs:string* external; +declare %a:since("expath-file", "1.0-20100517") %a:until("expath-file", "1.0-20120614") %a:missing("basex", "7.0") function file:files($path as xs:string, $pattern as xs:string, $recursive as xs:boolean) as xs:string* external; +declare %a:since("basex", "8.2") function file:is-absolute($path as xs:string) as xs:boolean external; +declare %a:since("expath-file", "1.0-20120614") function file:is-dir($path as xs:string) as xs:boolean external; +declare %a:since("expath-file", "1.0-20100517") %a:since("basex", "7.0") %a:until("expath-file", "1.0-20120614", "file:is-dir#1") %a:until("basex", "7.3", "file:is-dir#1") function file:is-directory($path as xs:string) as xs:boolean external; +declare %a:since("expath-file", "1.0-20100517") function file:is-file($path as xs:string) as xs:boolean external; +declare %a:since("expath-file", "1.0-20100517") function file:last-modified($path as xs:string) as xs:dateTime external; +declare %a:until("expath-file", "1.0-20120614") %a:since("basex", "7.3") function file:line-separator() as xs:string external; +declare %a:until("expath-file", "1.0-20120614") %a:since("basex", "7.0") function file:list($dir as xs:string) as xs:string* external; +declare %a:until("expath-file", "1.0-20120614") %a:since("basex", "7.0") function file:list($dir as xs:string, $recursive as xs:boolean) as xs:string* external; +declare %a:until("expath-file", "1.0-20120614") %a:since("basex", "7.0") function file:list($dir as xs:string, $recursive as xs:boolean, $pattern as xs:string) as xs:string* external; +declare %a:since("expath-file", "1.0-20100517") %a:until("expath-file", "1.0-20120614") %a:missing("basex", "7.0") function file:mkdir($dir as xs:string) as xs:boolean external; +declare %a:since("expath-file", "1.0-20100517") %a:until("expath-file", "1.0-20120614") %a:missing("basex", "7.0") function file:mkdir($dir as xs:string, $create as xs:boolean) as xs:boolean external; +declare %a:since("expath-file", "1.0-20100517") %a:until("expath-file", "1.0-20120614") %a:missing("basex", "7.0") function file:mkdirs($dir as xs:string) as xs:boolean external; +declare %a:since("expath-file", "1.0-20100517") %a:until("expath-file", "1.0-20120614") %a:missing("basex", "7.0") function file:mkdirs($dir as xs:string, $create as xs:boolean) as xs:boolean external; +declare %a:since("expath-file", "1.0-20120614") %a:since("basex", "7.0") function file:move($source as xs:string, $target as xs:string) as empty-sequence() external; +declare %a:since("expath-file", "1.0-20131203") function file:name($path as xs:string) as xs:string external; +declare %a:since("expath-file", "1.0-20131203") function file:parent($path as xs:string) as xs:string? external; +declare %a:since("expath-file", "1.0-20100517") function file:path-separator() as xs:string external; +declare %a:since("expath-file", "1.0-20100517") %a:until("expath-file", "1.0-20120614", "file:path-to-native#1") function file:path-to-full-path($path as xs:string) as xs:string external; +declare %a:since("expath-file", "1.0-20120614") %a:since("basex", "7.0") function file:path-to-native($path as xs:string) as xs:string external; +declare %a:since("expath-file", "1.0-20100517") function file:path-to-uri($path as xs:string) as path-uri-result external; +declare %a:since("expath-file", "1.0-20100517") %a:until("expath-file", "1.0-20120614", "file:read-binary#1") function file:read($file as xs:string) as xs:base64Binary external; +declare %a:since("expath-file", "1.0-20120614") %a:since("basex", "7.0") function file:read-binary($path as xs:string) as xs:base64Binary external; +declare %a:since("expath-file", "1.0-20131203") function file:read-binary($path as xs:string, $offset as xs:integer) as xs:base64Binary external; +declare %a:since("expath-file", "1.0-20131203") function file:read-binary($path as xs:string, $offset as xs:integer, $length as xs:integer) as xs:base64Binary external; +declare %a:since("expath-file", "1.0-20100517") %a:until("expath-file", "1.0-20120614") function file:read-html($file as xs:string, $tidyOptions as xs:string) as xs:string external; +declare %a:since("expath-file", "1.0-20100517") function file:read-text($file as xs:string) as xs:string external; +declare %a:since("expath-file", "1.0-20120614") %a:since("basex", "7.0") function file:read-text($path as xs:string, $encoding as xs:string) as xs:string external; +declare %a:since("basex", "8.5") function file:read-text($path as xs:string, $encoding as xs:string, $fallback as xs:boolean) as xs:string external; +declare %a:since("expath-file", "1.0-20120614") %a:since("basex", "7.0") function file:read-text-lines($path as xs:string) as xs:string* external; +declare %a:since("expath-file", "1.0-20120614") %a:since("basex", "7.0") function file:read-text-lines($path as xs:string, $encoding as xs:string) as xs:string* external; +declare %a:since("basex", "8.5") function file:read-text-lines($path as xs:string, $encoding as xs:string, $fallback as xs:boolean) as xs:string* external; +declare %a:since("basex", "9.0") function file:read-text-lines($path as xs:string, $encoding as xs:string, $fallback as xs:boolean, $offset as xs:integer) as xs:string* external; +declare %a:since("basex", "9.0") function file:read-text-lines($path as xs:string, $encoding as xs:string, $fallback as xs:boolean, $offset as xs:integer, $length as xs:integer) as xs:string* external; +declare %a:since("expath-file", "1.0-20100517") %a:until("expath-file", "1.0-20120614") %a:missing("basex", "7.0") function file:read-xml($file as xs:string) as node() external; +declare %a:since("expath-file", "1.0-20100517") %a:until("expath-file", "1.0-20120614") %a:missing("basex", "7.0") function file:read-xml($file as xs:string, $tidy as xs:boolean) as node() external; +declare %a:since("expath-file", "1.0-20100517") %a:until("expath-file", "1.0-20120614") %a:missing("basex", "7.0") function file:remove($path as xs:string) as xs:boolean external; +declare %a:since("expath-file", "1.0-20120614") %a:since("basex", "8.2") function file:resolve-path($path as xs:string) as xs:string external; +declare %a:since("basex", "8.2") function file:resolve-path($path as xs:string, $base as xs:string) as xs:string external; +declare %a:since("expath-file", "1.0-20120614") %a:since("basex", "7.0") function file:size($file as xs:string) as xs:integer external; +declare %a:since("expath-file", "1.0-20131203") %a:since("basex", "7.7") function file:temp-dir() as xs:string external; +declare %a:since("expath-file", "1.0-20120614") %a:since("basex", "7.0") function file:write($path as xs:string, $items as item()*) as empty-sequence() external; +declare %a:since("expath-file", "1.0-20100517") function file:write($file as xs:string, $content as item()*, $params as write-params) as copy-write-result external; +declare %a:since("expath-file", "1.0-20100517") %a:until("expath-file", "1.0-20120614") %a:missing("basex", "7.0") function file:write($file as xs:string, $content as item()*, $params as node()*, $append as xs:boolean) as xs:boolean external; +declare %a:since("expath-file", "1.0-20120614") %a:since("basex", "7.0") function file:write-binary($path as xs:string, $value as any-binary-type) as empty-sequence() external; +declare %a:since("expath-file", "1.0-20131203") function file:write-binary($path as xs:string, $value as any-binary-type, $offset as xs:integer) as empty-sequence() external; +declare %a:since("expath-file", "1.0-20120614") function file:write-text($path as xs:string, $value as xs:string) as empty-sequence() external; +declare %a:since("expath-file", "1.0-20120614") function file:write-text($path as xs:string, $value as xs:string, $encoding as xs:string) as empty-sequence() external; +declare %a:since("expath-file", "1.0-20120614") function file:write-text-lines($path as xs:string, $values as xs:string*) as empty-sequence() external; +declare %a:since("expath-file", "1.0-20120614") function file:write-text-lines($path as xs:string, $values as xs:string*, $encoding as xs:string) as empty-sequence() external; diff --git a/src/vue-poc/data/xquery.lib/expath.org/ns/geo.xqy b/src/vue-poc/data/xquery.lib/expath.org/ns/geo.xqy new file mode 100644 index 0000000..743334c --- /dev/null +++ b/src/vue-poc/data/xquery.lib/expath.org/ns/geo.xqy @@ -0,0 +1,116 @@ +xquery version "3.0"; +(:~ + : Geo Module (EXPath Candidate Module 30 September 2010) + : + : @see http://expath.org/spec/geo + : @see http://docs.basex.org/wiki/Geo_Module + :) +module namespace geo = "http://expath.org/ns/geo"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare namespace gml = "http://www.opengis.net/gml"; + +declare option o:requires "expath-crypto/1.0-20100930"; + +declare option o:implements-module "basex/7.6 as expath-geo/1.0-20100930"; +declare option o:requires-import "basex/7.6; location-uri=(none)"; + +declare type boundary-type = ( + %a:since("expath-crypto", "1.0-20100930") for element()* | + %a:since("basex", "7.6") for element()? +); + +declare type geo-type = ( + %a:since("expath-crypto", "1.0-20100930") for node() | + %a:since("basex", "7.6") for element() +); + +declare type opt-binary = ( + %a:since("expath-crypto", "1.0-20100930") for xs:base64Binary? | + %a:since("basex", "7.6") for xs:base64Binary +); + +declare type basex-opt-double = ( + %a:since("expath-crypto", "1.0-20100930") for xs:double | + %a:since("basex", "7.6") for xs:double? +); + +declare type opt-int = ( + %a:since("expath-crypto", "1.0-20100930") for xs:integer? | + %a:since("basex", "7.6") for xs:integer +); + +declare type opt-qname = ( + %a:since("expath-crypto", "1.0-20100930") for xs:QName? | + %a:since("basex", "7.6") for xs:QName +); + +declare type opt-string = ( + %a:since("expath-crypto", "1.0-20100930") for xs:string? | + %a:since("basex", "7.6") for xs:string +); + +declare type srid-type = ( + %a:since("expath-crypto", "1.0-20100930") for xs:anyURI? | + %a:since("basex", "7.6") for xs:integer +); + +declare %a:since("expath-crypto", "1.0-20100930") function geo:dimension($geometry as geo-type) as opt-int external; +declare %a:since("expath-crypto", "1.0-20100930") %a:missing("basex", "7.6") function geo:coordinate-dimension($geometry as node()) as xs:integer external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:geometry-type($geometry as geo-type) as opt-qname external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:srid($geometry as geo-type) as srid-type external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:envelope($geometry as geo-type) as element(gml:Envelope) external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:as-text($geometry as geo-type) as opt-string external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:as-binary($geometry as geo-type) as opt-binary external; +declare %a:since("expath-crypto", "1.0-20100930") %a:missing("basex", "7.6") function geo:is-empty($geometry as node()) as xs:boolean external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:is-simple($geometry as geo-type) as xs:boolean external; +declare %a:since("expath-crypto", "1.0-20100930") %a:missing("basex", "7.6") function geo:is-3d($geometry as node()) as xs:boolean external; +declare %a:since("expath-crypto", "1.0-20100930") %a:missing("basex", "7.6") function geo:is-measured($geometry as node()) as xs:boolean external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:boundary($geometry as geo-type) as element()? external; + +declare %a:since("expath-crypto", "1.0-20100930") function geo:equals($geometry1 as geo-type, $geometry2 as geo-type) as xs:boolean external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:disjoint($geometry1 as geo-type, $geometry2 as geo-type) as xs:boolean external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:intersects($geometry1 as geo-type, $geometry2 as geo-type) as xs:boolean external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:touches($geometry1 as geo-type, $geometry2 as geo-type) as xs:boolean external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:crosses($geometry1 as geo-type, $geometry2 as geo-type) as xs:boolean external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:within($geometry1 as geo-type, $geometry2 as geo-type) as xs:boolean external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:contains($geometry1 as geo-type, $geometry2 as geo-type) as xs:boolean external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:overlaps($geometry1 as geo-type, $geometry2 as geo-type) as xs:boolean external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:relate($geometry1 as geo-type, $geometry2 as geo-type, $intersectionMatrix as xs:string) as xs:boolean external; + +declare %a:since("expath-crypto", "1.0-20100930") function geo:distance($geometry1 as geo-type, $geometry2 as geo-type) as xs:double external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:buffer($geometry as geo-type, $distance as xs:double) as element() external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:convex-hull($geometry as geo-type) as element() external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:intersection($geometry1 as geo-type, $geometry2 as geo-type) as element()? external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:union($geometry1 as geo-type, $geometry2 as geo-type) as element() external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:difference($geometry1 as geo-type, $geometry2 as geo-type) as element()? external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:sym-difference($geometry1 as geo-type, $geometry2 as geo-type) as element()? external; + +declare %a:since("expath-crypto", "1.0-20100930") function geo:num-geometries($geometry as geo-type) as xs:integer external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:geometry-n($geometry as geo-type, $geoNumber as xs:integer) as element() external; + +declare %a:since("expath-crypto", "1.0-20100930") function geo:x($point as geo-type) as xs:double external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:y($point as geo-type) as basex-opt-double external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:z($point as geo-type) as xs:double? external; +declare %a:since("expath-crypto", "1.0-20100930") %a:missing("basex", "7.6") function geo:m($point as node()) as xs:double? external; + +declare %a:since("expath-crypto", "1.0-20100930") function geo:length($geometry as geo-type) as xs:double external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:start-point($line as geo-type) as element(gml:Point) external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:end-point($line as geo-type) as element(gml:Point) external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:is-closed($geometry as geo-type) as xs:boolean external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:is-ring($line as geo-type) as xs:boolean external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:num-points($geometry as geo-type) as xs:integer external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:point-n($line as geo-type, $n as xs:integer) as geo-type external; + +declare %a:since("expath-crypto", "1.0-20100930") function geo:area($geometry as geo-type) as xs:double external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:centroid($geometry as geo-type) as geo-type external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:point-on-surface($geometry as geo-type) as geo-type external; +declare %a:since("expath-crypto", "1.0-20100930") %a:missing("basex", "7.6") function geo:num-patches($surface as node()) as xs:integer external; +declare %a:since("expath-crypto", "1.0-20100930") %a:missing("basex", "7.6") function geo:patch-n($surface as node(), $n as xs:integer) as node() external; +declare %a:since("expath-crypto", "1.0-20100930") %a:missing("basex", "7.6") function geo:bounding-polgons($surface as node(), $polygon as node()) as element(gml:Polygon)* external; + +declare %a:since("expath-crypto", "1.0-20100930") function geo:exterior-ring($polygon as geo-type) as element(gml:LineString) external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:num-interior-ring($polygon as geo-type) as xs:integer external; +declare %a:since("expath-crypto", "1.0-20100930") function geo:interior-ring-n($polygon as element(), $n as xs:integer) as element(gml:LineString) external; diff --git a/src/vue-poc/data/xquery.lib/expath.org/ns/http-client.xqy b/src/vue-poc/data/xquery.lib/expath.org/ns/http-client.xqy new file mode 100644 index 0000000..fb5a852 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/expath.org/ns/http-client.xqy @@ -0,0 +1,19 @@ +xquery version "3.0"; +(:~ + : HTTP Client Module (EXPath Candidate Module 9 January 2010) + : + : @see http://expath.org/spec/http-client + : @see http://docs.basex.org/wiki/HTTP_Module + :) +module namespace http = "http://expath.org/ns/http-client"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "expath-http/1.0-20100109"; + +declare option o:implements-module "basex/7.1 as expath-http/1.0-20100109"; + +declare %a:since("expath-http", "1.0-20100109") function http:send-request($request as element(http:request)) as item()+ external; +declare %a:since("expath-http", "1.0-20100109") function http:send-request($request as element(http:request)?, $href as xs:string?) as item()+ external; +declare %a:since("expath-http", "1.0-20100109") function http:send-request($request as element(http:request)?, $href as xs:string?, $bodies as item()*) as item()+ external; diff --git a/src/vue-poc/data/xquery.lib/expath.org/ns/webapp.xqy b/src/vue-poc/data/xquery.lib/expath.org/ns/webapp.xqy new file mode 100644 index 0000000..79dac32 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/expath.org/ns/webapp.xqy @@ -0,0 +1,30 @@ +xquery version "3.0"; +(:~ + : Web Applications (EXPath Candidate Module 1 April 2013) + : + : @see http://expath.org/spec/webapp + :) +module namespace web = "http://expath.org/ns/webapp"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "expath-webapp/1.0-20130401"; + +declare %a:since("expath-webapp", "1.0-20130401") function web:config-param($name as xs:string) as xs:string? external; +declare %a:since("expath-webapp", "1.0-20130401") function web:config-param($name as xs:string, $default as xs:string?) as xs:string? external; +declare %a:since("expath-webapp", "1.0-20130401") function web:config-doc($name as xs:string) as document-node()? external; +declare %a:since("expath-webapp", "1.0-20130401") function web:get-request-field($name as xs:string) as item()* external; +declare %a:since("expath-webapp", "1.0-20130401") function web:set-request-field($name as xs:string, $value as item()*) as empty-sequence() external; +declare %a:since("expath-webapp", "1.0-20130401") function web:get-request-field-names() as xs:string* external; +declare %a:since("expath-webapp", "1.0-20130401") function web:get-session-field($name as xs:string) as item()* external; +declare %a:since("expath-webapp", "1.0-20130401") function web:set-session-field($name as xs:string, $value as item()*) as empty-sequence() external; +declare %a:since("expath-webapp", "1.0-20130401") function web:get-session-field-names() as xs:string* external; +declare %a:since("expath-webapp", "1.0-20130401") function web:get-webapp-field($name as xs:string) as item()* external; +declare %a:since("expath-webapp", "1.0-20130401") function web:set-webapp-field($name as xs:string, $value as item()*) as empty-sequence() external; +declare %a:since("expath-webapp", "1.0-20130401") function web:get-webapp-field-names() as xs:string* external; +declare %a:since("expath-webapp", "1.0-20130401") function web:get-container-field($name as xs:string) as item()* external; +declare %a:since("expath-webapp", "1.0-20130401") function web:set-container-field($name as xs:string, $value as item()*) as empty-sequence() external; +declare %a:since("expath-webapp", "1.0-20130401") function web:get-container-field-names() as xs:string* external; +declare %a:since("expath-webapp", "1.0-20130401") function web:parse-header-value($header as xs:string) as element(web:header) external; +declare %a:since("expath-webapp", "1.0-20130401") function web:parse-basic-auth($header as xs:string) as element(web:basic-auth) external; diff --git a/src/vue-poc/data/xquery.lib/expath.org/ns/zip.xqy b/src/vue-poc/data/xquery.lib/expath.org/ns/zip.xqy new file mode 100644 index 0000000..eddb066 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/expath.org/ns/zip.xqy @@ -0,0 +1,29 @@ +xquery version "3.0"; +(:~ + : ZIP Module (EXPath Candidate Module 12 October 2010) + : + : @see http://expath.org/spec/zip + : @see http://docs.basex.org/wiki/ZIP_Module + :) +module namespace zip = "http://expath.org/ns/zip"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "expath-zip/1.0-20101012"; + +declare option o:implements-module "basex/7.0 as expath-zip/1.0-20101012"; (: NOTE: 7.0 is the earliest version definitions are available for. :) + +declare type uri-type = ( + %a:since("expath-zip", "1.0-20101012") for xs:anyURI | + %a:since("basex", "7.0") for xs:string +); + +declare %a:since("expath-zip", "1.0-20101012") %a:deprecated("basex", "7.3", "archive:extract-binary") function zip:binary-entry($uri as uri-type, $path as xs:string) as xs:base64Binary external; +declare %a:since("expath-zip", "1.0-20101012") %a:deprecated("basex", "7.3", "archive:extract-text") function zip:text-entry($uri as uri-type, $path as xs:string) as xs:string external; +declare %a:since("basex", "7.0") %a:deprecated("basex", "7.3", "archive:extract-text") function zip:text-entry($uri as xs:string, $path as xs:string, $encoding as xs:string) as xs:string external; +declare %a:since("expath-zip", "1.0-20101012") %a:deprecated("basex", "7.3", "archive:extract-text") function zip:xml-entry($uri as uri-type, $path as xs:string) as document-node() external; +declare %a:since("expath-zip", "1.0-20101012") %a:deprecated("basex", "7.3", "archive:extract-text") function zip:html-entry($uri as uri-type, $path as xs:string) as document-node() external; +declare %a:since("expath-zip", "1.0-20101012") %a:deprecated("basex", "7.3", "archive:entries") function zip:entries($uri as uri-type) as element(zip:file) external; +declare %a:since("expath-zip", "1.0-20101012") %a:deprecated("basex", "7.3", "archive:create") function zip:zip-file($zip as element(zip:file)) as empty-sequence() external; +declare %a:since("expath-zip", "1.0-20101012") %a:deprecated("basex", "7.3", "archive:update") function zip:update-entries($zip as element(zip:file), $output as uri-type) as empty-sequence() external; diff --git a/src/vue-poc/data/xquery.lib/readme.md b/src/vue-poc/data/xquery.lib/readme.md new file mode 100644 index 0000000..6057d02 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/readme.md @@ -0,0 +1,6 @@ +xpath and xquery modules and functions + +Much from: +https://github.com/rhdunn/xquery-intellij-plugin/tree/f610832d111eece77a4e7d31659610cba598a468/src/plugin-w3/main/resources/builtin + +Note `.ignore` required for BaseX parsing \ No newline at end of file diff --git a/src/vue-poc/data/xquery.lib/www.w3.org/2001/XMLSchema.xqy b/src/vue-poc/data/xquery.lib/www.w3.org/2001/XMLSchema.xqy new file mode 100644 index 0000000..9fbaa2c --- /dev/null +++ b/src/vue-poc/data/xquery.lib/www.w3.org/2001/XMLSchema.xqy @@ -0,0 +1,58 @@ +xquery version "3.1"; +(:~ + : XPath and XQuery Functions and Operators: Constructor Functions + : + : @see https://www.w3.org/TR/2007/REC-xpath-functions-20070123/ + : @see https://www.w3.org/TR/2010/REC-xpath-functions-20101214/ + : @see https://www.w3.org/TR/2014/REC-xpath-functions-30-20140408/ + : @see https://www.w3.org/TR/2017/REC-xpath-functions-31-20170321/ + :) +module namespace xs = "http://www.w3.org/2001/XMLSchema"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; + +declare %a:since("xmlschema", "1.0-20010502") function xs:ENTITY($arg as xs:anyAtomicType?) as xs:ENTITY? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:ID($arg as xs:anyAtomicType?) as xs:ID? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:IDREF($arg as xs:anyAtomicType?) as xs:IDREF? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:NCName($arg as xs:anyAtomicType?) as xs:NCName? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:NMTOKEN($arg as xs:anyAtomicType?) as xs:NMTOKEN? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:Name($arg as xs:anyAtomicType?) as xs:Name? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:QName($arg (: as [1.0]xs:anyAtomicType [1.1]xs:anyAtomicType? :)) as xs:QName? external; + +declare %a:since("xmlschema", "1.0-20010502") function xs:anyURI($arg as xs:anyAtomicType?) as xs:anyURI? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:base64Binary($arg as xs:anyAtomicType?) as xs:base64Binary? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:boolean($arg as xs:anyAtomicType?) as xs:boolean? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:byte($arg as xs:anyAtomicType?) as xs:byte? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:date($arg as xs:anyAtomicType?) as xs:date? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:dateTime($arg as xs:anyAtomicType?) as xs:dateTime? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:dayTimeDuration($arg as xs:anyAtomicType?) as xs:dayTimeDuration? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:decimal($arg as xs:anyAtomicType?) as xs:decimal? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:double($arg as xs:anyAtomicType?) as xs:double? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:duration($arg as xs:anyAtomicType?) as xs:duration? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:float($arg as xs:anyAtomicType?) as xs:float? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:gDay($arg as xs:anyAtomicType?) as xs:gDay? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:gMonth($arg as xs:anyAtomicType?) as xs:gMonth? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:gMonthDay($arg as xs:anyAtomicType?) as xs:gMonthDay? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:gYear($arg as xs:anyAtomicType?) as xs:gYear? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:gYearMonth($arg as xs:anyAtomicType?) as xs:gYearMonth? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:hexBinary($arg as xs:anyAtomicType?) as xs:hexBinary? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:int($arg as xs:anyAtomicType?) as xs:int? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:integer($arg as xs:anyAtomicType?) as xs:integer? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:language($arg as xs:anyAtomicType?) as xs:language? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:long($arg as xs:anyAtomicType?) as xs:long? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:negativeInteger($arg as xs:anyAtomicType?) as xs:negativeInteger? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:nonNegativeInteger($arg as xs:anyAtomicType?) as xs:nonNegativeInteger? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:nonPositiveInteger($arg as xs:anyAtomicType?) as xs:nonPositiveInteger? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:normalizedString($arg as xs:anyAtomicType?) as xs:normalizedString? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:positiveInteger($arg as xs:anyAtomicType?) as xs:positiveInteger? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:short($arg as xs:anyAtomicType?) as xs:short? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:string($arg as xs:anyAtomicType?) as xs:string? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:time($arg as xs:anyAtomicType?) as xs:time? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:token($arg as xs:anyAtomicType?) as xs:token? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:unsignedByte($arg as xs:anyAtomicType?) as xs:unsignedByte? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:unsignedInt($arg as xs:anyAtomicType?) as xs:unsignedInt? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:unsignedLong($arg as xs:anyAtomicType?) as xs:unsignedLong? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:unsignedShort($arg as xs:anyAtomicType?) as xs:unsignedShort? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:untypedAtomic($arg as xs:anyAtomicType?) as xs:untypedAtomic? external; +declare %a:since("xmlschema", "1.0-20010502") function xs:yearMonthDuration($arg as xs:anyAtomicType?) as xs:yearMonthDuration? external; +declare %a:since("xmlschema", "1.1-20120405") function xs:dateTimeStamp($arg as xs:anyAtomicType?) as xs:dateTimeStamp? external; diff --git a/src/vue-poc/data/xquery.lib/www.w3.org/2005/xpath-functions.xqy b/src/vue-poc/data/xquery.lib/www.w3.org/2005/xpath-functions.xqy new file mode 100644 index 0000000..f4082ae --- /dev/null +++ b/src/vue-poc/data/xquery.lib/www.w3.org/2005/xpath-functions.xqy @@ -0,0 +1,249 @@ +xquery version "3.1"; +(:~ + : XPath and XQuery Functions and Operators + : + : @see https://www.w3.org/TR/2007/REC-xpath-functions-20070123/ + : @see https://www.w3.org/TR/2010/REC-xpath-functions-20101214/ + : @see https://www.w3.org/TR/2014/REC-xpath-functions-30-20140408/ + : @see https://www.w3.org/TR/201/REC-xpath-functions-31-20170321/ + : + : This software includes material copied from or derived from the XPath and + : XQuery Functions and Operators 1.0 to 3.1 specifications. Copyright © + : 2007-2017 W3C® (MIT, ERCIM, Keio, Beihang). + :) +module namespace fn = "http://www.w3.org/2005/xpath-functions"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "xpath-functions/1.0"; + +declare %a:since("xpath-functions", "1.0-20070123") function fn:QName($paramURI as xs:string?, $paramQName as xs:string) as xs:QName external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:abs($arg as xs:numeric?) as xs:numeric? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:adjust-date-to-timezone($arg as xs:date?) as xs:date? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:adjust-date-to-timezone($arg as xs:date?, $timezone as xs:dayTimeDuration?) as xs:date? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:adjust-dateTime-to-timezone($arg as xs:dateTime?) as xs:dateTime? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:adjust-dateTime-to-timezone($arg as xs:dateTime?, $timezone as xs:dayTimeDuration?) as xs:dateTime? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:adjust-time-to-timezone($arg as xs:time?) as xs:time? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:adjust-time-to-timezone($arg as xs:time?, $timezone as xs:dayTimeDuration?) as xs:time? external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:analyze-string($input as xs:string?, $pattern as xs:string) as element(fn:analyze-string-result) external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:analyze-string($input as xs:string?, $pattern as xs:string, $flags as xs:string) as element(fn:analyze-string-result) external; +declare %a:since("xpath-functions", "3.1-20170321") function fn:apply($function as function(*), $array as array(*)) as item()* external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:available-environment-variables() as xs:string* external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:avg($arg as xs:anyAtomicType*) as xs:anyAtomicType? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:base-uri() as xs:anyURI? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:base-uri($arg as node()?) as xs:anyURI? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:boolean($arg as item()*) as xs:boolean external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:ceiling($arg as xs:numeric?) as xs:numeric? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:codepoint-equal($comparand1 as xs:string?, $comparand2 as xs:string?) as xs:boolean? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:codepoints-to-string($arg as xs:integer*) as xs:string external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:collection() as node()* external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:collection($arg as xs:string?) as node()* external; +declare %a:since("xpath-functions", "3.1-20170321") function fn:collection-key($key as xs:string) as xs:base64Binary external; +declare %a:since("xpath-functions", "3.1-20170321") function fn:collection-key($key as xs:string, $collation as xs:string) as xs:base64Binary external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:compare($comparand1 as xs:string?, $comparand2 as xs:string?) as xs:integer? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:compare($comparand1 as xs:string?, $comparand2 as xs:string?, $collation as xs:string) as xs:integer? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:concat($arg1 as xs:anyAtomicType?, $arg2 as xs:anyAtomicType?, $args as xs:anyAtomicType?...) as xs:string external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:contains($arg1 as xs:string?, $arg2 as xs:string?) as xs:boolean external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:contains($arg1 as xs:string?, $arg2 as xs:string?, $collation as xs:string) as xs:boolean external; +declare %a:since("xpath-functions", "3.1-20170321") function fn:contains-token($input as xs:string*, $token as xs:string) as xs:boolean external; +declare %a:since("xpath-functions", "3.1-20170321") function fn:contains-token($input as xs:string*, $token as xs:string, $collation as xs:string) as xs:boolean external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:count($arg as item()*) as xs:integer external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:current-date() as xs:date external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:current-dateTime() as xs:dateTime external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:current-time() as xs:time external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:data() as xs:anyAtomicType* external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:data($arg as item()*) as xs:anyAtomicType* external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:dateTime($arg1 as xs:date?, $arg2 as xs:time?) as xs:dateTime? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:day-from-date($arg as xs:date?) as xs:integer? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:day-from-dateTime($arg as xs:dateTime?) as xs:integer? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:days-from-duration($arg as xs:duration?) as xs:integer? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:deep-equal($parameter1 as item()*, $parameter2 as item()*) as xs:boolean external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:deep-equal($parameter1 as item()*, $parameter2 as item()*, $collation as string) as xs:boolean external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:default-collation() as xs:string external; +declare %a:since("xpath-functions", "3.1-20170321") function fn:default-language() as xs:language external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:distinct-values($arg as xs:anyAtomicType*) as xs:anyAtomicType* external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:distinct-values($arg as xs:anyAtomicType*, $collation as xs:string) as xs:anyAtomicType* external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:doc($uri as xs:string?) as document-node()? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:doc-available($uri as xs:string?) as xs:boolean external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:document-uri() as xs:anyURI? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:document-uri($arg as node()?) as xs:anyURI? external; +declare %a:since("xpath-functions", "1.0-20101214") function fn:element-with-id($arg as xs:string*) as element()* external; +declare %a:since("xpath-functions", "1.0-20101214") function fn:element-with-id($arg as xs:string*, $node as node()) as element()* external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:empty($arg as item()*) as xs:boolean external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:encode-for-uri($uri-part as xs:string?) as xs:string external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:ends-with($arg1 as xs:string?, $arg2 as xs:string?) as xs:boolean external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:ends-with($arg1 as xs:string?, $arg2 as xs:string?, $collation as xs:string) as xs:boolean external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:environment-variable($name as xs:string) as xs:string? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:error() as none external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:error($error as xs:QName) as none external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:error($error as xs:QName?, $description as xs:string) as none external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:error($error as xs:QName?, $description as xs:string, $error-object as item()*) as none external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:escape-html-uri($uri as xs:string?) as xs:string external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:exactly-one($arg as item()*) as item() external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:exists($arg as item()*) as xs:boolean external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:false() as xs:boolean external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:filter($seq as item()*, $f as function(item()) as xs:boolean) as item()* external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:floor($arg as xs:numeric?) as xs:numeric? external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:fold-left($seq as item()*, $zero as item()*, $f as function(item()*, item()) as item()*) as item()* external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:fold-right($seq as item()*, $zero as item()*, $f as function(item()*, item()) as item()*) as item()* external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:for-each($seq as item()*, $f as function(item()) as item()*) as item()* external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:for-each-pair($seq1 as item()*, $seq2 as item()*, $f as function(item(), item()) as item()*) as item()* external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:format-date($value as xs:date?, $picture as xs:string) as xs:string? external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:format-date($value as xs:date?, $picture as xs:string, $language as xs:string?, $calendar as xs:string?, $place as xs:string?) as xs:string? external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:format-dateTime($value as xs:dateTime?, $picture as xs:string) as xs:string? external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:format-dateTime($value as xs:dateTime?, $picture as xs:string, $language as xs:string?, $calendar as xs:string?, $place as xs:string?) as xs:string? external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:format-integer($value as xs:integer?, $picture as xs:string) as xs:string external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:format-integer($value as xs:integer?, $picture as xs:string, $lang as xs:string?) as xs:string external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:format-number($value as xs:numeric?, $picture as xs:string) as xs:string external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:format-number($value as xs:numeric?, $picture as xs:string, $decimal-format-name as xs:string?) as xs:string external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:format-time($value as xs:time?, $picture as xs:string) as xs:string? external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:format-time($value as xs:time?, $picture as xs:string, $language as xs:string?, $calendar as xs:string?, $place as xs:string?) as xs:string? external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:function-arity($func as function(*)) as xs:integer external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:function-lookup($name as xs:QName, $arity as xs:integer) as function(*)? external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:function-name($func as function(*)) as xs:QName? external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:generate-id() as xs:string external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:generate-id($arg as node()?) as xs:string external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:has-children() as xs:boolean external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:has-children($node as node()?) as xs:boolean external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:head($arg as item()*) as item()? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:hours-from-dateTime($arg as xs:dateTime?) as xs:integer? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:hours-from-duration($arg as xs:duration?) as xs:integer? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:hours-from-time($arg as xs:time?) as xs:integer? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:id($arg as xs:string*) as element()* external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:id($arg as xs:string*, $node as node()) as element()* external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:idref($arg as xs:string*) as node()* external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:idref($arg as xs:string*, $node as node()) as node()* external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:implicit-timezone() as xs:dayTimeDuration external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:in-scope-prefixes($element as element()) as xs:string* external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:index-of($seqParam as xs:anyAtomicType*, $srchParam as xs:anyAtomicType) as xs:integer* external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:index-of($seqParam as xs:anyAtomicType*, $srchParam as xs:anyAtomicType, $collation as xs:string) as xs:integer* external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:innermost($nodes as node()*) as node()* external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:insert-before($target as item()*, $position as xs:integer, $inserts as item()*) as item()* external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:iri-to-uri($iri as xs:string?) as xs:string external; +declare %a:since("xpath-functions", "3.1-20170321") function fn:json-doc($href as xs:string?) as item()? external; +declare %a:since("xpath-functions", "3.1-20170321") function fn:json-doc($href as xs:string?, $options as map(*)) as item()? external; +declare %a:since("xpath-functions", "3.1-20170321") function fn:json-to-xml($json-text as xs:string?) as document-node()? external; +declare %a:since("xpath-functions", "3.1-20170321") function fn:json-to-xml($json-text as xs:string?, $options as map(*)) as document-node()? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:lang($testlang as xs:string?) as xs:boolean external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:lang($testlang as xs:string?, $node as node()) as xs:boolean external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:last() as xs:integer external; +declare %a:since("xpath-functions", "3.1-20170321") function fn:load-xquery-module($module-uri as xs:string) as map(*) external; +declare %a:since("xpath-functions", "3.1-20170321") function fn:load-xquery-module($module-uri as xs:string, $options as map(*)) as map(*) external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:local-name() as xs:string external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:local-name($arg as node()?) as xs:string external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:local-name-from-QName($arg as xs:QName?) as xs:NCName? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:lower-case($arg as xs:string?) as xs:string external; +declare %a:since("xpath-functions", "3.0-20111213") %a:until("xpath-functions", "3.0-20130108", "fn:for-each#2") function fn:map($f as function(item()) as item()*, $seq as item()*) as item()* external; +declare %a:since("xpath-functions", "3.0-20111213") %a:until("xpath-functions", "3.0-20130108", "fn:for-each-pair#3") function fn:map-pairs($seq1 as item()*, $seq2 as item()*, $f as function(item(), item()) as item()*) as item()* external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:matches($input as xs:string?, $pattern as xs:string) as xs:boolean external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:matches($input as xs:string?, $pattern as xs:string, $flags as xs:string) as xs:boolean external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:max($arg as xs:anyAtomicType*) as xs:anyAtomicType? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:max($arg as xs:anyAtomicType*, $collation as string) as xs:anyAtomicType? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:min($arg as xs:anyAtomicType*) as xs:anyAtomicType? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:min($arg as xs:anyAtomicType*, $collation as string) as xs:anyAtomicType? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:minutes-from-dateTime($arg as xs:dateTime?) as xs:integer? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:minutes-from-duration($arg as xs:duration?) as xs:integer? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:minutes-from-time($arg as xs:time?) as xs:integer? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:month-from-date($arg as xs:date?) as xs:integer? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:month-from-dateTime($arg as xs:dateTime?) as xs:integer? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:months-from-duration($arg as xs:duration?) as xs:integer? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:name() as xs:string external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:name($arg as node()?) as xs:string external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:namespace-uri() as xs:anyURI external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:namespace-uri($arg as node()?) as xs:anyURI external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:namespace-uri-for-prefix($prefix as xs:string?, $element as element()) as xs:anyURI? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:namespace-uri-from-QName($arg as xs:QName?) as xs:anyURI? external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:nilled() as xs:boolean external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:nilled($arg as node()?) as xs:boolean? external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:node-name() as xs:QName? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:node-name($arg as node()?) as xs:QName? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:normalize-space() as xs:string external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:normalize-space($arg as xs:string?) as xs:string external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:normalize-unicode($arg as xs:string?) as xs:string external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:normalize-unicode($arg as xs:string?, $normalizationForm as xs:string) as xs:string external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:not($arg as item()*) as xs:boolean external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:number() as xs:double external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:number($arg as xs:anyAtomicType?) as xs:double external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:one-or-more($arg as item()*) as item()+ external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:outermost($nodes as node()*) as node()* external; +declare %a:since("xpath-functions", "3.1-20170321") function fn:parse-ietf-date($value as xs:string?) as xs:dateTime? external; +declare %a:since("xpath-functions", "3.1-20170321") function fn:parse-json($json-text as xs:string?) as item()? external; +declare %a:since("xpath-functions", "3.1-20170321") function fn:parse-json($json-text as xs:string?, $options as map(*)) as item()? external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:parse-xml($arg as xs:string?) as document-node(element(*))? external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:parse-xml-fragment($arg as xs:string?) as document-node()? external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:path() as xs:string? external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:path($arg as node()?) as xs:string? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:position() as xs:integer external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:prefix-from-QName($arg as xs:QName?) as xs:NCName? external; +declare %a:since("xpath-functions", "3.1-20170321") function fn:random-number-generator() as map(xs:string, item()) external; +declare %a:since("xpath-functions", "3.1-20170321") function fn:random-number-generator($seed as xs:anyAtomicType?) as map(xs:string, item()) external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:remove($target as item()*, $position as xs:integer) as item()* external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:replace($input as xs:string?, $pattern as xs:string, $replacement as xs:string) as xs:string external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:replace($input as xs:string?, $pattern as xs:string, $replacement as xs:string, $flags as xs:string) as xs:string external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:resolve-QName($qname as xs:string?, $element as element()) as xs:QName? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:resolve-uri($relative as xs:string?) as xs:anyURI? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:resolve-uri($relative as xs:string?, $base as xs:string) as xs:anyURI? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:reverse($arg as item()*) as item()* external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:root() as node() external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:root($arg as node()?) as node()? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:round($arg as xs:numeric?) as xs:numeric? external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:round($arg as xs:numeric?, $precision as xs:integer) as xs:numeric? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:round-half-to-even($arg as xs:numeric?) as xs:numeric? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:round-half-to-even($arg as xs:numeric?, $precision as xs:integer) as xs:numeric? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:seconds-from-dateTime($arg as xs:dateTime?) as xs:decimal? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:seconds-from-duration($arg as xs:duration?) as xs:decimal? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:seconds-from-time($arg as xs:time?) as xs:decimal? external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:serialize($arg as item()*) as xs:string external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:serialize($arg as item()*, $params as item()?) as xs:string external; +declare %a:since("xpath-functions", "3.1-20170321") function fn:sort($input as item()*) as item()* external; +declare %a:since("xpath-functions", "3.1-20170321") function fn:sort($input as item()*, $collation as xs:string?) as item()* external; +declare %a:since("xpath-functions", "3.1-20170321") function fn:sort($input as item()*, $collation as xs:string?, $key as function(item()) as xs:anyAtomicType*) as item()* external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:starts-with($arg1 as xs:string?, $arg2 as xs:string?) as xs:boolean external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:starts-with($arg1 as xs:string?, $arg2 as xs:string?, $collation as xs:string) as xs:boolean external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:static-base-uri() as xs:anyURI? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:string() as xs:string external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:string($arg as item()?) as xs:string external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:string-join($arg1 as xs:string*) as xs:string external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:string-join($arg1 as xs:string*, $arg2 as xs:string) as xs:string external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:string-length() as xs:integer external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:string-length($arg as xs:string?) as xs:integer external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:string-to-codepoints($arg as xs:string?) as xs:integer* external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:subsequence($sourceSeq as item()*, $startingLoc as xs:double) as item()* external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:subsequence($sourceSeq as item()*, $startingLoc as xs:double, $length as xs:double) as item()* external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:substring($sourceString as xs:string?, $startingLoc as xs:double) as xs:string external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:substring($sourceString as xs:string?, $startingLoc as xs:double, $length as xs:double) as xs:string external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:substring-after($arg1 as xs:string?, $arg2 as xs:string?) as xs:string external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:substring-after($arg1 as xs:string?, $arg2 as xs:string?, $collation as xs:string) as xs:string external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:substring-before($arg1 as xs:string?, $arg2 as xs:string?) as xs:string external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:substring-before($arg1 as xs:string?, $arg2 as xs:string?, $collation as xs:string) as xs:string external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:sum($arg as xs:anyAtomicType*) as xs:anyAtomicType external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:sum($arg as xs:anyAtomicType*, $zero as xs:anyAtomicType?) as xs:anyAtomicType? external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:tail($arg as item()*) as item()? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:timezone-from-date($arg as xs:date?) as xs:dayTimeDuration? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:timezone-from-dateTime($arg as xs:dateTime?) as xs:dayTimeDuration? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:timezone-from-time($arg as xs:time?) as xs:dayTimeDuration? external; +declare %a:since("xpath-functions", "3.1-20170321") function fn:tokenize($input as xs:string?) as xs:string* external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:tokenize($input as xs:string?, $pattern as xs:string) as xs:string* external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:tokenize($input as xs:string?, $pattern as xs:string, $flags as xs:string) as xs:string* external; +declare %a:since("xpath-functions", "3.1-20170321") function fn:trace($value as item()*) as item()* external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:trace($value as item()*, $label as xs:string) as item()* external; +declare %a:since("xpath-functions", "3.1-20170321") function fn:transform($options as map(*)) as map(*) external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:translate($arg as xs:string?, $mapString as xs:string, $transString as xs:string) as xs:string external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:true() as xs:boolean external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:unordered($sourceSeq as item()*) as item()* external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:unparsed-text($href as xs:string?) as xs:string? external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:unparsed-text($href as xs:string?, $encoding as xs:string) as xs:string? external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:unparsed-text-available($href as xs:string?) as xs:string? external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:unparsed-text-available($href as xs:string?, $encoding as xs:string) as xs:string? external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:unparsed-text-lines($href as xs:string?) as xs:string? external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:unparsed-text-lines($href as xs:string?, $encoding as xs:string) as xs:string? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:upper-case($arg as xs:string?) as xs:string external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:uri-collection() as xs:anyURI* external; +declare %a:since("xpath-functions", "3.0-20140408") function fn:uri-collection($arg as xs:string?) as xs:anyURI* external; +declare %a:since("xpath-functions", "3.1-20170321") function fn:xml-to-json($input as node()?) as xs:string? external; +declare %a:since("xpath-functions", "3.1-20170321") function fn:xml-to-json($input as node()?, $options as map(*)) as xs:string? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:year-from-date($arg as xs:date?) as xs:integer? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:year-from-dateTime($arg as xs:dateTime?) as xs:integer? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:years-from-duration($arg as xs:duration?) as xs:integer? external; +declare %a:since("xpath-functions", "1.0-20070123") function fn:zero-or-one($arg as item()*) as item()? external; diff --git a/src/vue-poc/data/xquery.lib/www.w3.org/2005/xpath-functions/array.xqy b/src/vue-poc/data/xquery.lib/www.w3.org/2005/xpath-functions/array.xqy new file mode 100644 index 0000000..7784476 --- /dev/null +++ b/src/vue-poc/data/xquery.lib/www.w3.org/2005/xpath-functions/array.xqy @@ -0,0 +1,38 @@ +xquery version "3.1"; +(:~ + : XPath and XQuery Functions and Operators: Functions that Operate on Arrays + : + : @see https://www.w3.org/TR/2017/REC-xpath-functions-31-20170321/ + : + : This software includes material copied from or derived from the XPath and + : XQuery Functions and Operators 3.1 specifications. Copyright © 2017 W3C® + : (MIT, ERCIM, Keio, Beihang). + :) +module namespace array = "http://www.w3.org/2005/xpath-functions/array"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "xpath-functions/3.1"; + +declare %a:since("xpath-functions", "3.1-20170321") function array:append($array as array(*), $appendage as item()*) as array(*) external; +declare %a:since("xpath-functions", "3.1-20170321") function array:filter($array as array(*), $function as function(item()*) as xs:boolean) as array(*) external; +declare %a:since("xpath-functions", "3.1-20170321") function array:flatten($input as item()*) as item()* external; +declare %a:since("xpath-functions", "3.1-20170321") function array:fold-left($array as array(*), $zero as item()*, $function as function(item()*, item()*) as item()*) as item()* external; +declare %a:since("xpath-functions", "3.1-20170321") function array:fold-right($array as array(*), $zero as item()*, $function as function(item()*, item()*) as item()*) as item()* external; +declare %a:since("xpath-functions", "3.1-20170321") function array:for-each($array as array(*), $action as function(item()*) as item()*) as array(*) external; +declare %a:since("xpath-functions", "3.1-20170321") function array:for-each-pair($array1 as array(*), $array2 as array(*), $function as function(item()*, item()*) as item()*) as array(*) external; +declare %a:since("xpath-functions", "3.1-20170321") function array:get($array as array(*), $position as xs:integer) as item()* external; +declare %a:since("xpath-functions", "3.1-20170321") function array:head($array as array(*)) as item()* external; +declare %a:since("xpath-functions", "3.1-20170321") function array:insert-before($array as array(*), $position as xs:integer, $member as item()*) as array(*) external; +declare %a:since("xpath-functions", "3.1-20170321") function array:join($arrays as array(*)*) as array(*) external; +declare %a:since("xpath-functions", "3.1-20170321") function array:put($array as array(*), $position as xs:integer, $member as item()*) as array(*) external; +declare %a:since("xpath-functions", "3.1-20170321") function array:remove($array as array(*), $positions as xs:integer*) as array(*) external; +declare %a:since("xpath-functions", "3.1-20170321") function array:reverse($array as array(*)) as array(*) external; +declare %a:since("xpath-functions", "3.1-20170321") function array:size($array as array(*)) as xs:integer external; +declare %a:since("xpath-functions", "3.1-20170321") function array:sort($array as array(*)) as array(*) external; +declare %a:since("xpath-functions", "3.1-20170321") function array:sort($array as array(*), $collation as xs:string?) as array(*) external; +declare %a:since("xpath-functions", "3.1-20170321") function array:sort($array as array(*), $collation as xs:string?, $key as function(item()*) as xs:anyAtomicType*) as array(*) external; +declare %a:since("xpath-functions", "3.1-20170321") function array:subarray($array as array(*), $start as xs:integer) as array(*) external; +declare %a:since("xpath-functions", "3.1-20170321") function array:subarray($array as array(*), $start as xs:integer, $length as xs:integer) as array(*) external; +declare %a:since("xpath-functions", "3.1-20170321") function array:tail($array as array(*)) as array(*) external; diff --git a/src/vue-poc/data/xquery.lib/www.w3.org/2005/xpath-functions/map.xqy b/src/vue-poc/data/xquery.lib/www.w3.org/2005/xpath-functions/map.xqy new file mode 100644 index 0000000..4b29b4f --- /dev/null +++ b/src/vue-poc/data/xquery.lib/www.w3.org/2005/xpath-functions/map.xqy @@ -0,0 +1,28 @@ +xquery version "3.1"; +(:~ + : XPath and XQuery Functions and Operators: Functions that Operate on Maps + : + : @see https://www.w3.org/TR/2017/REC-xpath-functions-31-20170321/ + : + : This software includes material copied from or derived from the XPath and + : XQuery Functions and Operators 3.1 specifications. Copyright © 2017 W3C® + : (MIT, ERCIM, Keio, Beihang). + :) +module namespace map = "http://www.w3.org/2005/xpath-functions/map"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "xpath-functions/3.1"; + +declare %a:since("xpath-functions", "3.1-20170321") function map:contains($map as map(*), $key as xs:anyAtomicType) as xs:boolean external; +declare %a:since("xpath-functions", "3.1-20170321") function map:entry($key as xs:anyAtomicType, $value as item()*) as map(*) external; +declare %a:since("xpath-functions", "3.1-20170321") function map:find($input as item()*, $key as xs:anyAtomicType) as array(*) external; +declare %a:since("xpath-functions", "3.1-20170321") function map:for-each($map as map(*), $action as function(xs:anyAtomicType, item()*) as item()*) as item()* external; +declare %a:since("xpath-functions", "3.1-20170321") function map:get($map as map(*), $key as xs:anyAtomicType) as item()* external; +declare %a:since("xpath-functions", "3.1-20170321") function map:keys($map as map(*)) as xs:anyAtomicType* external; +declare %a:since("xpath-functions", "3.1-20170321") function map:merge($maps as map(*)*) as map(*) external; +declare %a:since("xpath-functions", "3.1-20170321") function map:merge($maps as map(*)*, $options as map(*)) as map(*) external; +declare %a:since("xpath-functions", "3.1-20170321") function map:put($map as map(*), $key as xs:anyAtomicType, $value as item()*) as map(*) external; +declare %a:since("xpath-functions", "3.1-20170321") function map:remove($map as map(*), $keys as xs:anyAtomicType*) as map(*) external; +declare %a:since("xpath-functions", "3.1-20170321") function map:size($map as map(*)) as xs:integer external; diff --git a/src/vue-poc/data/xquery.lib/www.w3.org/2005/xpath-functions/math.xqy b/src/vue-poc/data/xquery.lib/www.w3.org/2005/xpath-functions/math.xqy new file mode 100644 index 0000000..f48489d --- /dev/null +++ b/src/vue-poc/data/xquery.lib/www.w3.org/2005/xpath-functions/math.xqy @@ -0,0 +1,31 @@ +xquery version "3.0"; +(:~ + : XPath and XQuery Functions and Operators: Trigonometric and exponential functions + : + : @see https://www.w3.org/TR/2014/REC-xpath-functions-30-20140408/#trigonometry + : + : This software includes material copied from or derived from the XPath and + : XQuery Functions and Operators 3.0 specification. Copyright © 2017 W3C® + : (MIT, ERCIM, Keio, Beihang). + :) +module namespace math = "http://www.w3.org/2005/xpath-functions/math"; + +declare namespace a = "http://reecedunn.co.uk/xquery/annotations"; +declare namespace o = "http://reecedunn.co.uk/xquery/options"; + +declare option o:requires "xpath-functions/3.0"; + +declare %a:since("xpath-functions", "3.0-20140408") function math:acos($arg as xs:double?) as xs:double? external; +declare %a:since("xpath-functions", "3.0-20140408") function math:asin($arg as xs:double?) as xs:double? external; +declare %a:since("xpath-functions", "3.0-20140408") function math:atan($arg as xs:double?) as xs:double? external; +declare %a:since("xpath-functions", "3.0-20140408") function math:atan2($y as xs:double, $x as xs:double) as xs:double external; +declare %a:since("xpath-functions", "3.0-20140408") function math:cos($θ as xs:double?) as xs:double? external; +declare %a:since("xpath-functions", "3.0-20140408") function math:exp($arg as xs:double?) as xs:double? external; +declare %a:since("xpath-functions", "3.0-20140408") function math:exp10($arg as xs:double?) as xs:double? external; +declare %a:since("xpath-functions", "3.0-20140408") function math:log($arg as xs:double?) as xs:double? external; +declare %a:since("xpath-functions", "3.0-20140408") function math:log10($arg as xs:double?) as xs:double? external; +declare %a:since("xpath-functions", "3.0-20140408") function math:pi() as xs:double external; +declare %a:since("xpath-functions", "3.0-20140408") function math:pow($x as xs:double?, $y as xs:numeric) as xs:double? external; +declare %a:since("xpath-functions", "3.0-20140408") function math:sin($θ as xs:double?) as xs:double? external; +declare %a:since("xpath-functions", "3.0-20140408") function math:sqrt($arg as xs:double?) as xs:double? external; +declare %a:since("xpath-functions", "3.0-20140408") function math:tan($θ as xs:double?) as xs:double? external;