Loading TOC...

alert.ruleGetQuery

alert.ruleGetQuery(
   $rule as Object
) as cts.query

Summary

Get the cts.query corresponding to the rule's query expression.

Parameters
$rule The representation of a rule.

Example

  var alert = require("/MarkLogic/alert.xqy");

  alert.ruleGetQuery(
       alert.getAllRules("http://acme.com/alert/message-board", 
                         cts.wordQuery("dna"))[0])

  => cts.orQuery([cts.wordQuery("dna", ["lang=en"], 1), cts.wordQuery("rna", ["lang=en"], 1)], [])
  

Comments

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