Changes

Jump to navigation Jump to search
1,259 bytes removed ,  13:11, 24 May 2018
no edit summary
=Conventions=
All functions and errors in this module are assigned to the <code><nowiki>http://basex.org/modules/repo</nowiki></code> namespace, which is statically bound to the <code>{{Code|repo</code> }} prefix.<br/>All errors are assigned to the <code>http://basex.org/errors</code> namespace, which is statically bound to the <code>bxerr</code> prefix.
=Functions=
==repo:install==
 {|width='100%'
|-
| width='90120' | '''Signatures'''|<code><b>{{Func|repo:install</b>(|$path as xs:string) as |empty-sequence()</code>}}<br />
|-
| '''Summary'''
|Installs a package, or (since {{Version|7.2.1}}), replaces an existing package. The parameter <code>{{Code|$path</code> }} indicates the path to the package.<br />
|-
| '''Errors'''
|<b>[[XQuery Errors{{Error|not-found|#Packaging Errors|BXRE0001]]</b> is raised if the }} a package does not exist.<br /><b>[[XQuery Errors#Packaging Errors{{Error|BXRE0002]]</b> is raised if a package uses an invalid namespace URI.<br /><b>[[XQuery Errors#Packaging Errorsdescriptor|BXRE0003]]</b> is raised if the package to be installed requires a package which is still not installed.<br /><b>[[XQuery Errors#Packaging Errors|BXRE0004]]</b> is raised if }} the package descriptor is invalid.<br /><b>[[XQuery Errors{{Error|installed|#Packaging Errors|BXRE0005]]</b> is raised if }} the module contained in the package to be installed is already installed as part of another package.<br /><b>[[XQuery Errors{{Error|parse|#Packaging Errors|BXRE0006]]</b> is raised if }} an error occurred while parsing the package cannot be parsed.<br /><b>[[XQuery Errors{{Error|version|#Packaging Errors|BXRE0009]]</b> is raised if }} the package version is not supported.<br /><b>[[XQuery Errors#Packaging Errors|BXRE0010]]</b> is raised if the package contains an invalid JAR descriptor.<br /><b>[[XQuery Errors#Packaging Errors|BXRE0011]]</b> is raised if the package contains a JAR descriptor but it cannot be read.<br />
|}
==repo:delete==
 {|width='100%'
|-
| width='90120' | '''Signatures'''|<code><b>{{Func|repo:delete</b>(|$pkg as xs:string) as |empty-sequence()</code>}}<br />
|-
| '''Summary'''
|Deletes a package. The parameter <code>$pkg</code> indicates either the package name as specified in the package descriptor or (since {{VersionCode|7.2.1$pkg}}) indicates the package name, optionally suffixed with a hyphen dash and the package version.<br />
|-
| '''Errors'''
|<b>[[XQuery Errors{{Error|not-found|#Packaging Errors|BXRE0007]]</b> is raised if the }} a package cannot be deleteddoes not exist.<br /><b>[[XQuery Errors{{Error|delete|#Packaging Errors|BXRE0008]]</b> is raised if another package depends on }} the package to cannot be deleted.<br />
|}
==repo:list==
{{Mark|Updated in Version 7.2:}} {|width='100%'
|-
| width='90120' | '''Signatures'''|<code><b>{{Func|repo:list</b>() as ||element(package)*</code>}}<br />
|-
| '''Summary'''
{| class="wikitable" width="100%"
! width="5%110"|Code! width="95%"|Description|-|<code>BXRE0001</code>|The addressed package does not exist.
|-
|<code>BXRE0002</code>{{Code|delete}}|A The package uses an invalid namespace URIcannot be deleted because of dependencies, or because files are missing.
|-
|<code>BXRE0003</code>{{Code|The package to be installed requires a package which is not installed yet.|-|<code>BXRE0004</code>descriptor}}
|The package descriptor is invalid.
|-
|<code>BXRE0005</code>{{Code|installed}}
|The module contained in the package to be installed is already installed as part of another package.
|-
|<code>BXRE0006</code>{{Code|not-found}}|The A package cannot be parseddoes not exist.
|-
|<code>BXRE0009</code>{{Code|parse}}|An error occurred while parsing the package.|-|{{Code|version}}
|The package version is not supported.
|-
|<code>BXRE0010</code>
|The package contains an invalid JAR descriptor.
|-
|<code>BXRE0011</code>
|The package contains a JAR descriptor but it cannot be read.
|}
=Changelog=
===;Version 9.0 * Updated: error codes updated; errors now use the module namespace ;Version 7.2.1===
* Updated: [[#repo:install|repo:install]]: existing packages will be replaced
* Updated: [[#repo:delete|repo:delete]]: remove specific version of a package
===;Version 7.2===
* Updated: [[#repo:list|repo:list]] now returns nodes
The module was introduced with {{Version|7.1}}[[Category:XQuery]]
Bureaucrats, editor, reviewer, Administrators
13,550

edits

Navigation menu