Liking cljdoc? Tell your friends :D

com.yetanalytics.persephone.template.predicates


add-wrappedclj/smacro

(add-wrapped wrapped-fns f values)

Given a function wrapped using wrap-pred or add-wrapped, add a 2-ary predicate f only if the values are not nil.

Given a function wrapped using `wrap-pred` or `add-wrapped`,
add a 2-ary predicate `f` only if the values are not `nil`.
sourceraw docstring

all-matchable?clj/s

(all-matchable? coll)

Returns true iff every value in coll is matchable.

Returns `true` iff every value in `coll` is matchable.
sourceraw docstring

and-wrappedclj/smacro

(and-wrapped f1 f2)

Given two functions f1 and f2 wrapped using wrap-pred, return nil if both functions return true and the corresponding keywordized function name for the function that returns false. Short circuiting.

Given two functions `f1` and `f2` wrapped using `wrap-pred`, return `nil`
if both functions return `true` and the corresponding
keywordized function name for the function that returns false.
Short circuiting.
sourceraw docstring

any-matchable?clj/s

(any-matchable? coll)

Returns true iff at least one matchable value in coll exists.

Returns `true` iff at least one matchable value in `coll` exists.
sourceraw docstring

create-default-predclj/s

(create-default-pred {:keys [any all none]})

Returns a wrapped pred for when presence is recommended or is missing.

Returns a wrapped pred for when presence is `recommended` or is
missing.
sourceraw docstring

create-det-prop-predclj/s

(create-det-prop-pred {:keys [match-vals]})

Returns a wrapped pred for use with Determining Properties. prop-vals contains the values of the given Property.

Returns a wrapped pred for use with Determining Properties.
`prop-vals` contains the values of the given Property.
sourceraw docstring

create-excluded-predclj/s

(create-excluded-pred _)

Returns a wrapped pred for when presence is excluded.

Returns a wrapped pred for when presence is `excluded`.
sourceraw docstring

create-included-predclj/s

(create-included-pred {:keys [any all none]})

Returns a wrapped pred for when presence is included.

Returns a wrapped pred for when presence is `included`.
sourceraw docstring

create-rule-predclj/s

(create-rule-pred {:keys [presence] :as rule})

Given a rule, create a predicate that will validate a Statement against it. Returns the name of the atomic predicate that returns false, or nil if all return true.

Given a rule, create a predicate that will validate a Statement
against it. Returns the name of the atomic predicate that returns
`false`, or `nil` if all return `true`.
sourceraw docstring

every-val-present?clj/s

(every-val-present? presence-set vals-coll)

Return true if every value in presence-set can be found in vals-coll; false otherwise.

Return `true` if every value in `presence-set` can be found in
`vals-coll`; `false` otherwise.
sourceraw docstring

no-none-values?clj/s

(no-none-values? none-set vals-coll)

Return true if there are no values from vals-coll in none-set; false otherwise.

Return `true` if there are no values from `vals-coll` in `none-set`;
`false` otherwise.
sourceraw docstring

no-unmatch-vals?clj/s

(no-unmatch-vals? _all-set vals-coll)

Return true if no unmatchable values from vals-coll exist; false otherwise.

Return `true` if no unmatchable values from `vals-coll` exist;
`false` otherwise.
sourceraw docstring

none-matchable?clj/s

(none-matchable? coll)

Returns true iff no value in coll is matchable.

Returns `true` iff no value in `coll` is matchable.
sourceraw docstring

only-all-values?clj/s

(only-all-values? all-set vals-coll)

Return true is every value from vals-coll is in all-set; false otherwise.

Return `true` is every value from `vals-coll` is in `all-set`;
`false` otherwise.
sourceraw docstring

or-wrappedclj/smacro

(or-wrapped f1 f2)

Given two functions f1 and f2 wrapped using wrap-pred, return nil if either function returns true and the keywordized function name for the first function if both return false.

Given two functions `f1` and `f2` wrapped using `wrap-pred`, return `nil`
if either function returns `true` and the keywordized function
name for the first function if both return false.
sourceraw docstring

some-any-values?clj/s

(some-any-values? any-set vals-coll)

Return true if there's at least one value from vals-coll in any-set; false otherwise.

Return `true` if there's at least one value from `vals-coll` in
`any-set`; `false` otherwise.
sourceraw docstring

wrap-predclj/smacro

(wrap-pred f)

Wrap a predicate function f such that if f returns true, return nil, and if f returns false, return the keywordized name of f.

Wrap a predicate function `f` such that if `f` returns `true`,
return `nil`, and if `f` returns `false`, return the keywordized
name of `f`.
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close