(->a & exprs)
Compose a series of expressions left-to-right.
Compose a series of expressions left-to-right.
(anda)
(anda expr)
(anda expr1 expr2)
(anda expr1 expr2 & more-exprs)
Constructs a function that returns either the first falsey result from applying each expressions to the same argument or the last truthy result if all results where truthy.
Constructs a function that returns either the first falsey result from applying each expressions to the same argument or the last truthy result if all results where truthy.
(betweena limit-a limit-b expr)
(betweena limit-a limit-b default-value expr)
Constrain a numeric value between two limits. Both the upper and lower limits are inclusive. If no default-value is provided, use the first limit.
Constrain a numeric value between two limits. Both the upper and lower limits are inclusive. If no default-value is provided, use the first limit.
(conda expr)
(conda pred-expr expr)
(conda pred-expr expr & more-pred-expr-pairs)
Test a value with a seriese of applicative expressions. When an expression matches apply the corresponding applicative expression to the original value. Example: (conda neg? 0 odd? inc pos? (*a 2) 0)
Test a value with a seriese of applicative expressions. When an expression matches apply the corresponding applicative expression to the original value. Example: (conda neg? 0 odd? inc pos? (*a 2) 0)
(defaulta default-value expr)
Apply expr, return default-value if expr returns false or nil
Apply expr, return default-value if expr returns false or nil
Filter the results of an applicative expression with an applicative expression. All nils or empty collections will be pruned from the result.
Filter the results of an applicative expression with an applicative expression. All nils or empty collections will be pruned from the result.
Filter the results of an applicative expression with an applicative expression, and returns a vector. All nils or empty collections will be pruned from the result.
Filter the results of an applicative expression with an applicative expression, and returns a vector. All nils or empty collections will be pruned from the result.
(geta k)
Lookup a key in an associative collection
Lookup a key in an associative collection
(guard pred)
(guard pred expr)
Given a unary predicate function, returns a function which returns it's argument if it satisfies the predicate
Given a unary predicate function, returns a function which returns it's argument if it satisfies the predicate
(guardn pred)
(guardn pred constant)
(guardn pred expr1 expr2 & more-exprs)
Constructs a guard function using predicate of two or more arguments. [pred constant]: A guard of the predicate curried with a constant. [pred expr1 expr2 ...]: A guard of the predicate lifted with the expression arugments.
Constructs a guard function using predicate of two or more arguments. [pred constant]: A guard of the predicate curried with a constant. [pred expr1 expr2 ...]: A guard of the predicate lifted with the expression arugments.
Map an applicative expression over the results of another expression. All nils or empty collections will be pruned from the result.
Map an applicative expression over the results of another expression. All nils or empty collections will be pruned from the result.
Map an applicative expression over the results of another expression, and return the results in a vector. All nils or empty collections will be pruned from the result.
Map an applicative expression over the results of another expression, and return the results in a vector. All nils or empty collections will be pruned from the result.
(nota expr)
Construct a function that returns the boolean complement of the expression.
Construct a function that returns the boolean complement of the expression.
(ora)
(ora expr)
(ora expr1 & exprs)
Constructs a function that returns either the first truthy result from applying each expressions to the same argument or nil if no truthy results where returned.
Constructs a function that returns either the first truthy result from applying each expressions to the same argument or nil if no truthy results where returned.
Remove the results of an applicative expression with an applicative expression. All nils or empty collections will be pruned from the result.
Remove the results of an applicative expression with an applicative expression. All nils or empty collections will be pruned from the result.
Remove the results of an applicative expression with an applicative expression, and returns a vector. All nils or empty collections will be pruned from the result.
Remove the results of an applicative expression with an applicative expression, and returns a vector. All nils or empty collections will be pruned from the result.
(selecta & keys)
Returns a map containing only the specified keys
Returns a map containing only the specified keys
(some->a & exprs)
Compose a series of expressions from left to right that will abort when one expression returns nil
Compose a series of expressions from left to right that will abort when one expression returns nil
(something? x)
Returns true when 'x is not nil or an empty collection
Returns true when 'x is not nil or an empty collection
Transforms an applicative expression into a function. Expressions may consist of functions, primitive values, and collections of functions and primitive values
Transforms an applicative expression into a function. Expressions may consist of functions, primitive values, and collections of functions and primitive values
Transforms an applicative expression into a function. Expressions may consist of functions, primitive values, and collections of functions and primitive values
Transforms an applicative expression into a function. Expressions may consist of functions, primitive values, and collections of functions and primitive values
(when-nota pred-expr expr)
When pred-expr does not return a truthy value for the argument then apply expr to the argument.
(when-nota pos? (*a -1))
When pred-expr does not return a truthy value for the argument then apply expr to the argument. (when-nota pos? (*a -1))
(whena pred-expr expr)
When pred-expr returns truthy value for the argument then apply expr to the argument.
When pred-expr returns truthy value for the argument then apply expr to the argument.
(withouta & keys)
Dissociate a group of keys from an associative collecion
Dissociate a group of keys from an associative collecion
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close