Constructs a WorkflowState from named channel specifications.
Arguments
- ...
Named arguments, each a
list(default = <value>)optionally with areducerelement. Ifreduceris absent,reducer_last_n()with a window of 20 is used for list channels andreducer_overwrite()for all other channels.
Value
A WorkflowState object.
Examples
ws <- workflow_state(
messages = list(default = list(), reducer = reducer_append()),
status = list(default = "pending")
)
ws$get("status")
#> [1] "pending"