Loading TOC...

clang functions

The table below lists all the clang built-in functions (in this namespace: http://marklogic.com/xdmp/custom-language).

Use the custom language management functions to configure plugin stemmers and tokenizers for specific languages in MarkLogic Server. The custom language module is installed as the following file:

  • install_dir/Modules/MarkLogic/custom-language.xqy

where install_dir is the directory in which MarkLogic Server is installed.

Many of these functions provide new configuration information. You must explictly update the configuration by calling clang.languageConfigWrite in the same statement that you use the functions in order for them to take effect.

To use this module in your own code, use a require statement similar to the following:

const clang = require('/MarkLogic/custom-language.xqy');

Calling clang.languageConfigWrite restarts the server so that your changes can take effect.

For more details, see Configuring Tokenization and Stemming Plugins in the Search Developer's Guide.

9 functions
Function name Description
clang.deleteUserLanguage This function returns user languages configuration with any existing configuration item for a given language removed.
clang.languageConfigDelete This function removes all custom language configuration from the cluster configuration files.
clang.languageConfigRead This function reads the custom language configuration specification from the cluster configuration files.
clang.languageConfigWrite This function saves a custom language configuration specification to the cluster configuration files.
clang.lexer This function constructs a custom lexer configuration item, suitable for use with clang.userLanguagePlugin.
clang.stemmer This function constructs a custom stemmer configuration item, suitable for use with clang.userLanguagePlugin.
clang.updateUserLanguage Add or replace a configuration item for a language in the given language configuration item, and return the new configuration.
clang.userLanguage This function constructs a user language configuration item, suitable for use with clang.updateUserLanguage.
clang.userLanguagePlugin This function constructs a user language plugin configuration item, suitable for use with clang.userLanguage.