(custom f)
Mark a function as a custom handler.
A custom handler is a function (f handlers depth condition normally)
that returns a function (f' value)
.
Mark a function as a custom handler. A custom handler is a function `(f handlers depth condition normally)` that returns a function `(f' value)`.
(default value)
Handle the condition with a constant value or a simple function of the value.
Handle the condition with a constant value or a simple function of the value.
(error message)
(error message ex-data)
Handle a condition by throwing an ex-info
Handle a condition by throwing an ex-info
(error* message)
(error* message ex-data)
Handle a condition by throwing an ex-info
Handle a condition by throwing an ex-info
(exception class message)
(exception class message cause)
Handle a condition by instantiating and throwing an exception of the given class with the given message and cause.
Handle a condition by instantiating and throwing an exception of the given class with the given message and cause.
(fall-through f)
(fall-through next-handler f)
(fall-through next-handler f override-normally)
Continue searching for handlers from the parent scope. Similar to handle
if it were to always return :continue.
f alters the value (because if you don't need to do anything at this scope you don't need a handler at all)
next-handler acts like remap
except that the search still starts at the parent scope
override-normally changes the default handler.
Continue searching for handlers from the parent scope. Similar to `handle` if it were to always return :continue. f alters the value (because if you don't need to do anything at this scope you don't need a handler at all) next-handler acts like `remap` except that the search still starts at the parent scope override-normally changes the default handler.
(handle f)
Handle the condition with a simple function of the value.
If the function returns :continue, continue searching handlers from the parent scope.
Handle the condition with a simple function of the value. If the function returns :continue, continue searching handlers from the parent scope.
Use to indicate that handling a condition is optional. If nothing handles the condition, return the value unmodified.
Use to indicate that handling a condition is optional. If nothing handles the condition, return the value unmodified.
(remap next-handler)
(remap next-handler f)
(remap next-handler f override-normally)
Restart the condition handler search from the beginning with a new condition key.
If next-handler is a function, it will be called with the value and the returned value will be the new condition key.
If f is provided, uses the value it returns as the new value for the new condition.
The default handler can also be overridden by providing override-normally.
Restart the condition handler search from the beginning with a new condition key. If next-handler is a function, it will be called with the value and the returned value will be the new condition key. If f is provided, uses the value it returns as the new value for the new condition. The default handler can also be overridden by providing override-normally.
Use to indicate that handling a condition is required. If nothing handles the condition, throw an ex-info.
Use to indicate that handling a condition is required. If nothing handles the condition, throw an ex-info.
(sibling next-handler)
(sibling next-handler f)
(sibling next-handler f override-normally)
Identical to remap
except that the search resumes at the current scope.
Identical to `remap` except that the search resumes at the current scope.
Just print that something happened and return the value
Just print that something happened and return the value
(trace-value message value)
Print a message and return the given value. Ignores any value provided by the restart.
Print a message and return the given value. Ignores any value provided by the restart.
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close