Diffo - TMF Service and Resource Management with a difference
Util - various utilities for NBN domain
Summary
Functions
Extracts a field value from a named item value map in a list, each value map is unwrapped with Diffo.Unwrap protocol
Generates a new random NBN identifier with the prefix
Returns whether the identifier is a valid NBN identifier
Functions
Extracts a field value from a named item value map in a list, each value map is unwrapped with Diffo.Unwrap protocol
Examples
iex> DiffoExample.Nbn.Util.extract([%{name: :avc, value: %{cvlan: 1}}], :avc, :cvlan) 1
Generates a new random NBN identifier with the prefix
Examples
iex> identifier = DiffoExample.Nbn.Util.identifier("AVC") iex> DiffoExample.Nbn.Util.identifier?(identifier) true
Returns whether the identifier is a valid NBN identifier
Examples
iex> DiffoExample.Nbn.Util.identifier?("AVC120123456789") true iex> DiffoExample.Nbn.Util.identifier?("avc120123456789") false