Grizzly.ZWave.SmartStart.MetaExtension behaviour (grizzly v0.15.8) View Source

Meta Extension support for SmartRent devices

Link to this section Summary

Functions

Take an Extension.t() and turn it into a binary

Given a binary string with meta extensions, can be in any order, decode it and return a list of MetaExtension.t()

Take a list of Extension.t()s and turn them into a binary string

Link to this section Types

Link to this section Functions

Link to this function

extension_to_binary(extension)

View Source

Specs

extension_to_binary(t()) :: binary()

Take an Extension.t() and turn it into a binary

Link to this function

extensions_from_binary(binary)

View Source

Specs

extensions_from_binary(binary()) ::
  {:ok, [t()]}
  | {:error, :invalid_meta_extensions_binary}
  | {:error, module(), reason :: any()}

Given a binary string with meta extensions, can be in any order, decode it and return a list of MetaExtension.t()

Link to this function

extensions_to_binary(extension_list)

View Source

Specs

extensions_to_binary([t()]) :: binary()

Take a list of Extension.t()s and turn them into a binary string

Link to this section Callbacks

Specs

from_binary(binary()) :: {:ok, t()} | {:error, reason :: any()}

Specs

to_binary(t()) :: {:ok, binary()}