OpenThread  1.05.03.02
Public Member Functions | Private Attributes
MeshLocalPrefixTlv Class Reference

#include <meshcop_tlvs.hpp>

+ Inheritance diagram for MeshLocalPrefixTlv:
+ Collaboration diagram for MeshLocalPrefixTlv:

Public Member Functions

const Ip6::NetworkPrefixGetMeshLocalPrefix (void) const
 
uint8_t GetMeshLocalPrefixLength (void) const
 
void Init (void)
 
bool IsValid (void) const
 
void SetMeshLocalPrefix (const Ip6::NetworkPrefix &aMeshLocalPrefix)
 
- Public Member Functions inherited from Tlv
TlvGetNext (void)
 
const TlvGetNext (void) const
 
Type GetType (void) const
 
void SetType (Type aType)
 
- Public Member Functions inherited from Tlv
Error AppendTo (Message &aMessage) const
 
uint8_t GetLength (void) const
 
TlvGetNext (void)
 
const TlvGetNext (void) const
 
uint32_t GetSize (void) const
 
uint8_t GetType (void) const
 
uint8_t * GetValue (void)
 
const uint8_t * GetValue (void) const
 
bool IsExtended (void) const
 
void SetLength (uint8_t aLength)
 
void SetType (uint8_t aType)
 

Private Attributes

Ip6::NetworkPrefix mMeshLocalPrefix
 

Additional Inherited Members

- Public Types inherited from Tlv
enum  Type : uint8_t {
  kChannel = OT_MESHCOP_TLV_CHANNEL, kPanId = OT_MESHCOP_TLV_PANID, kExtendedPanId = OT_MESHCOP_TLV_EXTPANID, kNetworkName = OT_MESHCOP_TLV_NETWORKNAME,
  kPskc = OT_MESHCOP_TLV_PSKC, kNetworkKey = OT_MESHCOP_TLV_NETWORKKEY, kNetworkKeySequence = OT_MESHCOP_TLV_NETWORK_KEY_SEQUENCE, kMeshLocalPrefix = OT_MESHCOP_TLV_MESHLOCALPREFIX,
  kSteeringData = OT_MESHCOP_TLV_STEERING_DATA, kBorderAgentLocator = OT_MESHCOP_TLV_BORDER_AGENT_RLOC, kCommissionerId = OT_MESHCOP_TLV_COMMISSIONER_ID, kCommissionerSessionId = OT_MESHCOP_TLV_COMM_SESSION_ID,
  kSecurityPolicy = OT_MESHCOP_TLV_SECURITYPOLICY, kGet = OT_MESHCOP_TLV_GET, kActiveTimestamp = OT_MESHCOP_TLV_ACTIVETIMESTAMP, kCommissionerUdpPort = OT_MESHCOP_TLV_COMMISSIONER_UDP_PORT,
  kState = OT_MESHCOP_TLV_STATE, kJoinerDtlsEncapsulation = OT_MESHCOP_TLV_JOINER_DTLS, kJoinerUdpPort = OT_MESHCOP_TLV_JOINER_UDP_PORT, kJoinerIid = OT_MESHCOP_TLV_JOINER_IID,
  kJoinerRouterLocator = OT_MESHCOP_TLV_JOINER_RLOC, kJoinerRouterKek = OT_MESHCOP_TLV_JOINER_ROUTER_KEK, kProvisioningUrl = OT_MESHCOP_TLV_PROVISIONING_URL, kVendorName = OT_MESHCOP_TLV_VENDOR_NAME_TLV,
  kVendorModel = OT_MESHCOP_TLV_VENDOR_MODEL_TLV, kVendorSwVersion = OT_MESHCOP_TLV_VENDOR_SW_VERSION_TLV, kVendorData = OT_MESHCOP_TLV_VENDOR_DATA_TLV, kVendorStackVersion = OT_MESHCOP_TLV_VENDOR_STACK_VERSION_TLV,
  kUdpEncapsulation = OT_MESHCOP_TLV_UDP_ENCAPSULATION_TLV, kIp6Address = OT_MESHCOP_TLV_IPV6_ADDRESS_TLV, kPendingTimestamp = OT_MESHCOP_TLV_PENDINGTIMESTAMP, kDelayTimer = OT_MESHCOP_TLV_DELAYTIMER,
  kChannelMask = OT_MESHCOP_TLV_CHANNELMASK, kCount = OT_MESHCOP_TLV_COUNT, kPeriod = OT_MESHCOP_TLV_PERIOD, kScanDuration = OT_MESHCOP_TLV_SCAN_DURATION,
  kEnergyList = OT_MESHCOP_TLV_ENERGY_LIST, kDiscoveryRequest = OT_MESHCOP_TLV_DISCOVERYREQUEST, kDiscoveryResponse = OT_MESHCOP_TLV_DISCOVERYRESPONSE, kJoinerAdvertisement = OT_MESHCOP_TLV_JOINERADVERTISEMENT
}
 
- Public Types inherited from SimpleTlvInfo< Tlv::kMeshLocalPrefix, Ip6::NetworkPrefix >
typedef Ip6::NetworkPrefix ValueType
 The TLV Value type. More...
 
- Static Public Member Functions inherited from Tlv
static Error FindTlv (const Message &aMessage, Type aType, uint16_t aMaxLength, Tlv &aTlv)
 
template<typename TlvType >
static Error FindTlv (const Message &aMessage, TlvType &aTlv)
 
static TlvFindTlv (uint8_t *aTlvsStart, uint16_t aTlvsLength, Type aType)
 
static const TlvFindTlv (const uint8_t *aTlvsStart, uint16_t aTlvsLength, Type aType)
 
template<typename TlvType >
static TlvType * FindTlv (uint8_t *aTlvsStart, uint16_t aTlvsLength)
 
template<typename TlvType >
static const TlvType * FindTlv (const uint8_t *aTlvsStart, uint16_t aTlvsLength)
 
static bool IsValid (const Tlv &aTlv)
 
- Static Public Member Functions inherited from Tlv
template<typename TlvType >
static Error Append (Message &aMessage, const void *aValue, uint8_t aLength)
 
template<typename SimpleTlvType >
static Error Append (Message &aMessage, const typename SimpleTlvType::ValueType &aValue)
 
template<typename UintTlvType >
static Error Append (Message &aMessage, typename UintTlvType::UintValueType aValue)
 
template<typename TlvType >
static Error Find (const Message &aMessage, void *aValue, uint8_t aLength)
 
template<typename SimpleTlvType >
static Error Find (const Message &aMessage, typename SimpleTlvType::ValueType &aValue)
 
template<typename UintTlvType >
static Error Find (const Message &aMessage, typename UintTlvType::UintValueType &aValue)
 
static Error FindTlv (const Message &aMessage, uint8_t aType, uint16_t aMaxSize, Tlv &aTlv)
 
template<typename TlvType >
static Error FindTlv (const Message &aMessage, TlvType &aTlv)
 
static Error FindTlvOffset (const Message &aMessage, uint8_t aType, uint16_t &aOffset)
 
static Error FindTlvValueOffset (const Message &aMessage, uint8_t aType, uint16_t &aValueOffset, uint16_t &aLength)
 
template<typename SimpleTlvType >
static Error Read (const Message &aMessage, uint16_t aOffset, typename SimpleTlvType::ValueType &aValue)
 
template<typename UintTlvType >
static Error Read (const Message &aMessage, uint16_t aOffset, typename UintTlvType::UintValueType &aValue)
 
static Error ReadTlv (const Message &aMessage, uint16_t aOffset, void *aValue, uint8_t aMinLength)
 
- Static Public Attributes inherited from Tlv
static constexpr uint8_t kBaseTlvMaxLength = OT_NETWORK_BASE_TLV_MAX_LENGTH
 
- Static Public Attributes inherited from TlvInfo< kTlvTypeValue >
static constexpr uint8_t kType = kTlvTypeValue
 The TLV Type value. More...
 
- Static Protected Attributes inherited from Tlv
static const uint8_t kExtendedLength = 255
 

Detailed Description

This class implements Mesh Local Prefix TLV generation and parsing.

Member Function Documentation

§ Init()

void Init ( void  )
inline

This method initializes the TLV.

References Tlv::kMeshLocalPrefix, Tlv::SetLength(), and Tlv::SetType().

§ IsValid()

bool IsValid ( void  ) const
inline

This method indicates whether or not the TLV appears to be well-formed.

Return values
TRUEIf the TLV appears to be well-formed.
FALSEIf the TLV does not appear to be well-formed.

References Tlv::GetLength().

§ GetMeshLocalPrefixLength()

uint8_t GetMeshLocalPrefixLength ( void  ) const
inline

This method returns the size (in bytes) of the Mesh Local Prefix field.

Returns
The size (in bytes) of the Mesh Local Prefix field (8 bytes).

§ GetMeshLocalPrefix()

const Ip6::NetworkPrefix& GetMeshLocalPrefix ( void  ) const
inline

This method returns the Mesh Local Prefix value.

Returns
The Mesh Local Prefix value.

§ SetMeshLocalPrefix()

void SetMeshLocalPrefix ( const Ip6::NetworkPrefix aMeshLocalPrefix)
inline

This method sets the Mesh Local Prefix value.

Parameters
[in]aMeshLocalPrefixA pointer to the Mesh Local Prefix value.

Field Documentation

§ mMeshLocalPrefix

Ip6::NetworkPrefix mMeshLocalPrefix
private

The documentation for this class was generated from the following file:
© Copyright 1995-2022, Texas Instruments Incorporated. All rights reserved.
Trademarks | Privacy policy | Terms of use | Terms of sale