XDR.VariableArray (Elixir XDR v0.3.11) View Source

This module manages the Variable-Length Array type based on the RFC4506 XDR Standard.

Link to this section Summary

Types

t()

XDR.VariableArray structure type specification.

Functions

Decode the Variable-Length Array in XDR format to a XDR.VariableArray structure.

Decode the Variable-Length Array in XDR format to a XDR.VariableArray structure. If the binaries are not valid, an exception is raised.

Encode a XDR.VariableArray structure into a XDR format.

Encode a XDR.VariableArray structure into a XDR format. If the variable_array is not valid, an exception is raised.

Create a new XDR.VariableArray structure with the elements, type and max_length passed.

Link to this section Types

Specs

elements() :: list() | binary()

Specs

t() :: %XDR.VariableArray{
  elements: elements(),
  max_length: integer(),
  type: module()
}

XDR.VariableArray structure type specification.

Link to this section Functions

Decode the Variable-Length Array in XDR format to a XDR.VariableArray structure.

Link to this function

decode_xdr!(bytes, struct)

View Source

Decode the Variable-Length Array in XDR format to a XDR.VariableArray structure. If the binaries are not valid, an exception is raised.

Encode a XDR.VariableArray structure into a XDR format.

Link to this function

encode_xdr!(variable_array)

View Source

Encode a XDR.VariableArray structure into a XDR format. If the variable_array is not valid, an exception is raised.

Link to this function

new(elements, type, max_length \\ 4294967295)

View Source

Specs

new(elements :: elements(), type :: module(), max_length :: integer()) :: t()

Create a new XDR.VariableArray structure with the elements, type and max_length passed.