(create-rule-predicate {:keys [location selector] :as rule})
Given rule
, create a function that returns true or false when
validating Statements against it.
Given `rule`, create a function that returns true or false when validating Statements against it.
(create-rule-validator {:keys [location selector] :as rule})
Given rule
, create a function that will validate new Statements
against the rule.
Given `rule`, create a function that will validate new Statements against the rule.
(create-template-predicate template ?statement-ref-fns)
Like create-template-validator
, but returns a predicate that takes
a Statement as an argument and returns a boolean.
Like `create-template-validator`, but returns a predicate that takes a Statement as an argument and returns a boolean.
(create-template-validator template ?statement-ref-fns)
Given template
, return a validator function that takes a
Statement as an argument and returns an nilable seq of error data.
Given `template`, return a validator function that takes a Statement as an argument and returns an nilable seq of error data.
(find-values stmt loc-path)
(find-values stmt loc-path select-path)
Given a Statement stmt
, a parsed location JSONPath loc-path
,
and an optional selector JSONPath select-path
, return a vector
of the selected values. Unmatchable values are returned as nils.
Given a Statement `stmt`, a parsed location JSONPath `loc-path`, and an optional selector JSONPath `select-path`, return a vector of the selected values. Unmatchable values are returned as nils.
(parse-locator locator)
Parse the locator
path.
Parse the `locator` path.
(parse-selector selector)
Conform and parse the selector
path to be used on values returned
by a locator.
Conform and parse the `selector` path to be used on values returned by a locator.
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close