prx_task (prx v0.14.1) View Source

Link to this section Summary

Link to this section Types

Specs

config() ::
    {init, fun((prx:task()) -> {ok, prx:task()} | {error, prx:posix()})} |
    {terminate, fun((prx:task(), prx:task()) -> any())}.

Specs

op() ::
    {function(), list()} |
    {module(), function(), list()} |
    {module(), function(), list(), [option()]}.

Specs

option() ::
    state | errexit |
    {state, boolean()} |
    {errexit, boolean()} |
    {transform, fun((any()) -> ok | {ok, State :: any()} | {error, prx:posix()})}.

Link to this section Functions

Specs

do(prx:task(), [op() | [op()]], any()) -> {ok, prx:task()} | {error, prx:posix()}.
Link to this function

do(Parent, Ops, State, Config)

View Source

Specs

do(prx:task(), [op() | [op()]], any(), [config()]) -> {ok, prx:task()} | {error, prx:posix()}.

Specs

with(prx:task(), [op() | [op()]], any()) ->
        ok | {error, any()} | {badop, {module(), function(), list()}, [op()]} | {badarg, any()}.