View Source Flamel.Contextable protocol (flamel v1.10.0)

The Flamel.Contextable protocol for working with something that stores a generic data structure and has the ability to.

Summary

Types

t()

All the types that implement this protocol.

Functions

Merges values in a map into the assigns in the context.

Assigns a value to a key in the context.

Signals to further functions in the pipeline that processing should stop

Has the context been halted?

Signals to further functions in the pipeline that processing should resume

Types

@type t() :: term()

All the types that implement this protocol.

Functions

@spec assign(term(), map() | keyword()) :: term()

Merges values in a map into the assigns in the context.

Link to this function

assign(context, key, value)

View Source
@spec assign(term(), binary() | atom(), term()) :: term()

Assigns a value to a key in the context.

@spec halt!(term(), binary()) :: term()

Signals to further functions in the pipeline that processing should stop

@spec halted?(term()) :: boolean()

Has the context been halted?

@spec resume!(term()) :: term()

Signals to further functions in the pipeline that processing should resume