![]() Import module namespace m = '' m:hello ( "Universe" ) Java įor general notes on importing Java classes, please read the Java Bindings article on Module Imports. Installation (the original file will be copied to the org/basex/modules/Hello subdirectory of the repository): xqm file suffix, and the original file will possibly be renamed and copied to that path into the repository. If the file can successfully be parsed, the module URI will be rewritten to a file path and attached with the. If an XQuery file is specified as input for the install command, it will be parsed as XQuery library module. The names of all packages are listed, along with their version, their package type, and the repository path:Ī package can be deleted with REPO DELETE and an additional argument, containing its name or the name suffixed with a hyphen and the package version: If you know that your input is valid, you may as well copy the files directly to the repository directory, or edit its contents in the repository without deleting and reinstalling them.Īll currently installed packages can be listed with REPO LIST. ![]() The installation will only succeed if the specified file conforms to the constraints described below. The path to the file has to be given as a parameter: You can even manually add and remove packages in the repository directory all changes will automatically be detected by BaseX.Ī module or package can be installed with REPO INSTALL. Call XQuery functions of the Repository Module.Execute BaseX REPO commands (listed below).There are various ways to organize your packages: Import module namespace functx = '' functx:capitalize-first ( 'test' ) Commands Import module statements must be placed at the beginning of a module: The specified location may be absolute or relative in the latter case, it is resolved against the location (i.e., static base URI) of the calling module. Library modules can be imported with the import module statement, followed by a freely choosable prefix and the namespace of the target module. xar archive, which encapsulates one or more extension libraries. ![]() The EXPath Packaging system provides a generic mechanism for adding XQuery modules to query processors.The internal Packaging mechanism will install single XQuery and JAR modules in the repository.As XQuery comes with only 150 pre-defined functions, which cannot meet all requirements, additional library modules exist – such as FunctX – which extend the language with new features.īaseX offers the following mechanisms to make external modules accessible to the XQuery processor: One of the things that makes languages successful is the availability of external libraries. ![]()
0 Comments
Leave a Reply. |