|
|
xdmp:amp(
|
|
$namespace as xs:string,
|
|
$localname as xs:string,
|
|
$module-uri as xs:string,
|
|
$database as xs:unsignedLong
|
| ) as xs:integer |
|
 |
Summary:
Returns the amp ID for the specified amp. Unlike the security
library module function sec:uid-for-name, this function
can be evaluted against any database and does not need to be evaluated
directly against the security database. It returns the amp ID from the
security database configured for the database in which the App Server
evaluates against.
|
Parameters:
$namespace
:
A function namespace.
|
$localname
:
A function localname.
|
$module-uri
:
The module URI for the amp.
|
$database
:
The ID of the database in which the module to which this amp refers is
stored. If the module is on the filesystem under the Modules
directory, then specify 0 for the database ID.
|
|
Example:
xdmp:amp("http://my-app/test","my-func","/modules/my-module.xqy",
xdmp:modules-database())
=> 2392349873545
|
Example:
xdmp:amp("http://marklogic.com/xdmp/security", "amp-add-roles",
"/MarkLogic/security.xqy", 0)
=> 3548369234520018804
|
|
|