EctoLtree v0.2.0 EctoLtree.LabelTree View Source

This module defines the LabelTree struct. Implements the Ecto.Type behaviour.

Fields

  • labels

Link to this section Summary

Functions

Provides custom casting rules from external data to internal representation.

From internal representation to database.

From database to internal representation.

Returns the underlying schema type.

Link to this section Types

Link to this type

t() View Source
t() :: %EctoLtree.LabelTree{labels: [String.t()]}

Link to this section Functions

Link to this function

cast(string) View Source
cast(String.t()) :: {:ok, t()} | :error

Provides custom casting rules from external data to internal representation.

Link to this function

decode(label_tree) View Source
decode(t()) :: String.t()

Link to this function

dump(label_tree) View Source
dump(t()) :: {:ok, String.t()} | :error

From internal representation to database.

Link to this function

load(labelpath) View Source
load(String.t()) :: {:ok, t()} | :error

From database to internal representation.

Returns the underlying schema type.