View Source Tw.JSON.Serializer behaviour (Tw v0.1.1)

JSON serializer constract.

Link to this section Summary

Types

Module which implements the Tw.JSON.Serializer behavior.

Link to this section Types

Specs

decode_options() :: keyword()

Specs

encode_options() :: keyword()

Specs

implementation() :: module()

Module which implements the Tw.JSON.Serializer behavior.

Link to this section Callbacks

Link to this callback

decode(iodata, decode_options)

View Source

Specs

decode(iodata(), decode_options()) :: {:ok, term()} | {:error, Exception.t()}
Link to this callback

encode(iodata, encode_options)

View Source

Specs

encode(iodata(), encode_options()) :: {:ok, iodata()} | {:error, Exception.t()}