yggdrasil v4.0.0 Yggdrasil.Transformer.Json View Source
JSON Yggdrasil transformer using the library Jason
.
Link to this section Summary
Functions
Returns a specification to start this module under a supervisor
Decodes a JSON from a binary message
. The channel
is ignored
Encodes some data
to a JSON binary. The channel
is ignored
Link to this section Functions
Returns a specification to start this module under a supervisor.
See Supervisor
.
Link to this function
decode(channel, message)
View Source
decode(Yggdrasil.Channel.t(), binary()) :: {:ok, map()} | {:error, term()}
Decodes a JSON from a binary message
. The channel
is ignored.
Link to this function
encode(channel, message)
View Source
encode(Yggdrasil.Channel.t(), binary()) :: {:ok, binary()} | {:error, term()}
Encodes some data
to a JSON binary. The channel
is ignored.