View Source CliexMap.PipelineFunctions (CliexMap v0.2.2)

Implements all functions the compiler compiles to. It is like a runtime, but as we will always use them in the Mapper's pipeline the naming seems appropriate

Summary

Functions

Function that represents fields like %, %2 or %-3

Fucnction that represents literal strings in the pattern, e.g. %% or Hello World

Types

@type ast() :: any()
@type binaries() :: [binary()]
@type binary?() :: maybe(binary())
@type color_list() :: [binary() | atom()]
Link to this type

either(success_t, error_t)

View Source
@type either(success_t, error_t) :: {:ok, success_t} | {:error, error_t}
@type line_nb_t() :: non_neg_integer()
@type maybe(t) :: nil | t
@type name_value_pair_t() :: {binary(), any()}
@type numbered_line_t() :: {line_nb_t(), binary()}

Functions

Link to this function

field_function(field_number)

View Source
@spec field_function(integer()) :: CliexMap.Fn.t()

Function that represents fields like %, %2 or %-3

Link to this function

literal_function(literal)

View Source
@spec literal_function(binary()) :: CliexMap.Fn.t()

Fucnction that represents literal strings in the pattern, e.g. %% or Hello World

Link to this function

map_either(either_value, mapper)

View Source
@spec map_either(either(success_t, error_t), (success_t -> transformed_t)) ::
  either(transformed_t, error_t)
when success_t: any(), error_t: any(), transformed_t: any()