kvasir v0.0.4 Kvasir.Type.Serializer View Source

Link to this section Summary

Link to this section Types

Link to this type

field()

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

Link to this section Functions

Link to this function

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

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

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

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