(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`.
(all-matchable? coll)
Returns true
iff every value in coll
is matchable.
Returns `true` iff every value in `coll` is matchable.
(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.
(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.
(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.
(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.
(create-excluded-pred _)
Returns a wrapped pred for when presence is excluded
.
Returns a wrapped pred for when presence is `excluded`.
(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`.
(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`.
(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.
(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.
(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.
(none-matchable? coll)
Returns true
iff no value in coll
is matchable.
Returns `true` iff no value in `coll` is matchable.
(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.
(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.
(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.
(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`.
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close