Namespace: replace

replace

Provides functions that maintain patch replacement libraries on the REST server. The client must have been created for a user with the rest-admin role.

Methods


list() → {ResultProvider}

Lists the patch replacement libraries installed on the server.
Since:
  • 1.0
Returns:
an object whose result() function takes a success callback that receives the list of replacement libraries
Type
ResultProvider

read(moduleName) → {ResultProvider}

Reads a patch replacement library installed on the server.
Parameters:
Name Type Description
moduleName string the filename without a path for the patch replacement library
Since:
  • 1.0
Returns:
an object whose result() function takes a success callback that receives the source code for the library
Type
ResultProvider

remove(moduleName)

Deletes a patch replacement library from the server.
Parameters:
Name Type Description
moduleName string the filename without a path for the patch replacement library
Since:
  • 1.0

write(moduleName, permissions, source)

Installs a patch replacement library on the server.
Parameters:
Name Type Argument Description
moduleName string the filename without a path for the patch replacement library; the filename must end in an extension registered in the server's mime type mapping table for the mime type of the source code format; at present, the extension should be ".xqy"
permissions Array.<object> <optional>
the permissions controlling which users can read, update, or execute the patch replacement library
source string the source code for the patch replacement library; at present, the source code must be XQuery
Since:
  • 1.0
Copyright (c) 2020 MarkLogic Corporation Documentation generated by JSDoc 3.6.4 on 2020-08-04T23:55:49-07:00 using the DocStrap template.