Documentation
¶
Overview ¶
Package actionstate keeps the state each action leaves between its runs, for the runs of a job and for the calls of an action caller alike.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Sendable ¶
Sendable turns a state into the form it takes when it is sent to an action in a process of its own, as sdk.Sendable does. It is given to New for this package not to import the sdk package, which imports this one.
type Store ¶
type Store struct {
// contains filtered or unexported fields
}
Store holds the state each action leaves, keyed by the name of the action. A nil Store keeps nothing. Its methods may be called concurrently.
func (*Store) Get ¶
Get returns a copy of the state the action left, or nil when it left none. A runner in this process may change what it is given, and the state kept must not change with it, should the step then fail or time out.
func (*Store) Set ¶
Set records the state the action leaves, in the form it takes when it is sent, which is a copy of it: a runner in this process may still hold the state it returned. A nil state keeps the one there was. A state that cannot be sent is an error, as it is for an action in a process of its own.