Loading TOC...

spell.load

spell.load(
   $path as String,
   $uri as String
) as null

Summary

Add the words from the file specified in $path to the dictionary at $uri. If a document exists with the specified URI, it is replaced with this one. Note that words that are 64 characters or greater will never be returned as suggestions from spell.suggest or spell.suggestDetailed.

Parameters
$path The path to a file containing the dictionary.
$uriThe URI of the dictionary.

Usage Notes

Dictionaries loaded with the spell.load function are automatically added to the following collections:

Example

  var spell = require("/MarkLogic/spell");
  declareUpdate();
  
  spell.load("c:\dictionaries\spell.json", "/mySpell/spell.json")
  

Comments

    Powered by MarkLogic Server 7.0-4.1 and rundmc | Terms of Use | Privacy Policy