Reactor.Builder.Compose (reactor v0.15.0)
View SourceHandle composition of Reactors for the builder.
The composition logic was getting complicated enough that it seemed sensible to extract it from the builder - if only to aid readability.
You should not use this module directly, but instead use
Reactor.Builder.compose/4
.
Summary
Functions
Compose another Reactor inside this one.
Verify that the arguments and reactor inputs match
Functions
@spec compose( Reactor.t(), atom(), Reactor.t() | module(), [Reactor.Builder.step_argument()], keyword() ) :: {:ok, Reactor.t()} | {:error, any()}
Compose another Reactor inside this one.
Options
:guards
(list of value that implements theReactor.Guard.Build
protocol) - Any guards which need to be added to the generated step The default value is[]
.:async?
(boolean/0
) - Whether the nested Reactor is allowed to run async or not The default value istrue
.
@spec verify_arguments(Reactor.t() | module(), [Reactor.Builder.step_argument()]) :: :ok | {:error, {:extra_args | :missing_args, MapSet.t(), MapSet.t()}}
Verify that the arguments and reactor inputs match