Kvasir.Type.Serializer (kvasir v0.0.15) View Source

Link to this section Summary

Link to this section Types

Specs

field() :: {name :: atom(), type :: module(), opts :: Keyword.t()}

Link to this section Functions

Link to this function

decode(fields, data, opts \\ [])

View Source

Specs

decode([field()], map(), Keyword.t()) ::
  {:ok, %{required(atom()) => term()}} | {:error, reason :: atom()}
Link to this function

encode(fields, data, opts \\ [])

View Source

Specs

encode([field()], map(), Keyword.t()) ::
  {:ok, %{required(atom()) => term()}} | {:error, reason :: atom()}