View Source Flamel.Chain (flamel v1.10.0)
Represents a chain of functions that can be executed in a pipeline.
Summary
Functions
Applies a function to the value of the chain. If the function returns a {:ok, value}
the chain's value is updated. If the function returns a {:error, reason, value}
then the chain is halted and not further functions will be applied. The chain's reason will be set to the reason provided in the error tuple.
Creates a function that can be used with Enum.map/1
to build a chain for each
item in the enumerable.
Create a new chain with a value. The value is the value that the chain's functions are applied to.
Types
Flamel.Chain
@type value() :: any()
Functions
Applies a function to the value of the chain. If the function returns a {:ok, value}
the chain's value is updated. If the function returns a {:error, reason, value}
then the chain is halted and not further functions will be applied. The chain's reason will be set to the reason provided in the error tuple.
Creates a function that can be used with Enum.map/1
to build a chain for each
item in the enumerable.
Create a new chain with a value. The value is the value that the chain's functions are applied to.