View Source SMPPEX.Pdu.NetworkErrorCode (smppex v3.2.1)

Module for operating with deliver_sm network_error_code parameter.

Link to this section Summary

Functions

Converts octet_string from network_error_code tag to type_code and error_value

Converts network_error_code type and error to octet string

Link to this section Types

@type error_code() :: pos_integer()
@type network_error_code() :: <<_::24>>
@type type_code() :: pos_integer()

Link to this section Functions

@spec decode(network_error_code()) :: {type_code(), error_code()}

Converts octet_string from network_error_code tag to type_code and error_value

example

Example

iex(1)> SMPPEX.Pdu.NetworkErrorCode.decode(<<08,00,01>>)
{8, 1}
Link to this function

encode(type_code, error_code)

View Source
@spec encode(type_code(), error_code()) :: network_error_code()

Converts network_error_code type and error to octet string

example

Example

iex(1)> SMPPEX.Pdu.NetworkErrorCode.encode(8,1)
<<08,00,01>>