<commit_before>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;<commit_msg>Annotate the BaseX client functions with versioned type restrictions.<commit_after>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:restrict-until("$bindings", "basex", "8.0", "map(*)")
        %a:since("basex", "7.3") function client:query($id as xs:anyURI, $query as xs:string, $bindings as map(*)?) as item()* external;
declare %a:since("basex", "7.3") function client:close($id as xs:anyURI) as empty-sequence() external;
{'fraction_non_alphanumeric': 0.17808798646362098, 'fraction_numerical': 0.016074450084602367, 'mean_word_length': 6.059701492537314, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1373761', 'n_tokens_mistral': 854, 'n_tokens_neox': 801, 'n_words': 224}