Glific v0.3.1 Glific.Flows.Case View Source

The Case object which encapsulates one category in a given node.

Link to this section Summary

Functions

Execute a case, given a message. This is the only execute function which has a different signature, since it just consumes one message at a time and executes it against a predefined function It also returns a boolean, rather than a tuple

Process a json structure from floweditor to the Glific data types

Link to this section Types

Specs

t() :: %Glific.Flows.Case{
  arguments: [String.t()],
  category: Glific.Flows.Category.t() | nil,
  category_uuid: Ecto.UUID.t() | nil,
  id: term(),
  name: term(),
  type: Glific.Enums.FlowCase | nil,
  uuid: Ecto.UUID.t() | nil
}

Link to this section Functions

Link to this function

execute(c, context, msg)

View Source

Specs

Execute a case, given a message. This is the only execute function which has a different signature, since it just consumes one message at a time and executes it against a predefined function It also returns a boolean, rather than a tuple

Link to this function

process(json, uuid_map, object \\ nil)

View Source

Specs

process(map(), map(), any()) :: {t(), map()}

Process a json structure from floweditor to the Glific data types