BACnet.Protocol.PropertyRef (bacstack v0.1.0-dev.1)

Copy Markdown View Source

A Property Reference names only a property (and optionally an array index) without identifying the object that contains it. It is used in contexts where the object is already known from surrounding context.

Summary

Types

t()

References a specific property (and optionally an array index) of an object.

Functions

Encodes a BACnet property reference into application tags encoding.

Parses a BACnet property reference into a struct.

Validates whether the given property reference is in form valid.

Types

t()

@type t() :: %BACnet.Protocol.PropertyRef{
  property_array_index: non_neg_integer() | nil,
  property_identifier:
    BACnet.Protocol.Constants.property_identifier() | non_neg_integer()
}

References a specific property (and optionally an array index) of an object.

Functions

encode(ref, opts \\ [])

@spec encode(t(), Keyword.t()) ::
  {:ok, BACnet.Protocol.ApplicationTags.encoding_list()} | {:error, term()}

Encodes a BACnet property reference into application tags encoding.

parse(tags)

Parses a BACnet property reference into a struct.

valid?(t)

@spec valid?(t()) :: boolean()

Validates whether the given property reference is in form valid.

It only validates the struct is valid as per type specification.