(as-step-fn flow)
DEPRECATED with no replacement.
DEPRECATED with no replacement.
(current-description)
Returns a flow that returns the description as of the point of execution.
For internal use. Subject to change.
Returns a flow that returns the description as of the point of execution. For internal use. Subject to change.
(flow description & flows)
Creates a flow which is a composite of flows.
Creates a flow which is a composite of flows.
(flow* {:keys [description caller-meta]} & flows)
For use in macros that create flows. Not private (appropriate for helper libraries, for example), but not intended for use directly in flows.
Creates a flow which is a composite of flows. The calling macro should
provide (meta &form) as :caller-meta
in order to support accurate line
number reporting.
For use in macros that create flows. Not private (appropriate for helper libraries, for example), but not intended for use directly in flows. Creates a flow which is a composite of flows. The calling macro should provide (meta &form) as `:caller-meta` in order to support accurate line number reporting.
(ignore-error pair)
No-op error handler that simply ignores the error.
No-op error handler that simply ignores the error.
(log-and-throw-error! pair)
Error handler that logs the error and throws an exception to notify the flow has failed.
Error handler that logs the error and throws an exception to notify the flow has failed.
(modify-meta f & args)
Returns a monad that will apply vary-meta to the world.
For internal use. Subject to change.
Returns a monad that will apply vary-meta to the world. For internal use. Subject to change.
(pop-meta)
Returns a flow that will modify the state metadata.
For internal use. Subject to change.
Returns a flow that will modify the state metadata. For internal use. Subject to change.
(push-meta description {:keys [line]})
Returns a flow that will modify the state metadata.
For internal use. Subject to change.
Returns a flow that will modify the state metadata. For internal use. Subject to change.
(run flow)
(run flow initial-state)
Given an initial-state (default {}), runs a flow and returns a tuple of the result of the last step in the flow and the end state.
Given an initial-state (default {}), runs a flow and returns a tuple of the result of the last step in the flow and the end state.
(run! flow)
(run! flow initial-state)
DEPRECATED. Use run*
DEPRECATED. Use `run*`
(run* {:keys [init cleanup runner on-error]
:or {init (constantly {})
cleanup identity
runner run
on-error log-and-throw-error!}
:as opts}
flow)
Runs a flow with specified parameters. Use run
unless you need
the customizations run*
supports.
Supported keys in the first argument are:
init
optional, default (constantly {}), function of no arguments that returns the initial state
cleanup
optional, default identity, function of the final state used to perform cleanup, if necessary
runner
optional, default run
, function of a flow and an initial state which will execute the flow
on-error
optional, default log-and-throw-error!
, function of the final result pair to be invoked
when the first value in the pair represents an error
Runs a flow with specified parameters. Use `run` unless you need the customizations `run*` supports. Supported keys in the first argument are: `init` optional, default (constantly {}), function of no arguments that returns the initial state `cleanup` optional, default identity, function of the final state used to perform cleanup, if necessary `runner` optional, default `run`, function of a flow and an initial state which will execute the flow `on-error` optional, default `log-and-throw-error!`, function of the final result pair to be invoked when the first value in the pair represents an error
(runner)
Creates a flow that returns the runner (function). Useful for helpers that need to access the runner.
Creates a flow that returns the runner (function). Useful for helpers that need to access the runner.
(top-level-description s)
Returns the description passed to the top level flow (or the stringified symbol passed to defflow).
Returns the description passed to the top level flow (or the stringified symbol passed to defflow).
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close