(allow-keys allowed-keys & [msg])
Validates that the map MAY contain keys listed, and no keys not listed
Validates that the map MAY contain keys listed, and no keys not listed
(col-predicate col f & [msg])
Require that f, a predicate, returns truthy when passed (get obj col)
Require that f, a predicate, returns truthy when passed (get obj col)
(key-type k cls)
Validates that the column is of the specified class
Validates that the column is of the specified class
(key-types ks)
Takes a map of keys to classes. Validates that each key in map is of the specified class.
Takes a map of keys to classes. Validates that each key in map is of the specified class.
(map-predicate f s)
Calls a validation fn on each item in coll, returning the first call to return an error string
Calls a validation fn on each item in coll, returning the first call to return an error string
(maybe f)
HOF, takes a predicate, and returns a fn that is true if argument passed in is nil, or passes the predicate.
((maybe integer?) 3) => true ((maybe integer?) nil) => true ((maybe integer?) :bogus) => false
HOF, takes a predicate, and returns a fn that is true if argument passed in is nil, or passes the predicate. ((maybe integer?) 3) => true ((maybe integer?) nil) => true ((maybe integer?) :bogus) => false
(require-keys keys)
Validates that the map contains all of the keys
Validates that the map contains all of the keys
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close