class WeaveMessageLayer
Defined at line 522 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveMessageLayer.h
The definition of the WeaveMessageLayer class, which manages communication
with other Weave nodes. It employs one of several InetLayer endpoints
to establish a communication channel with other Weave nodes.
Public Members
System::Layer * SystemLayer
InetLayer * Inet
WeaveFabricState * FabricState
void * AppState
WeaveExchangeManager * ExchangeMgr
WeaveSecurityManager * SecurityMgr
uint32_t IncomingConIdleTimeout
uint8_t State
bool IsListening
bool mDropMessage
MessageReceiveFunct OnMessageReceived
TunneledMsgReceiveFunct OnUDPTunneledMessageReceived
ReceiveErrorFunct OnReceiveError
ConnectionReceiveFunct OnConnectionReceived
AcceptErrorFunct OnAcceptError
BleLayer * mBle
Public Methods
void WeaveMessageLayer ()
WEAVE_ERROR Init (InitContext * context)
WEAVE_ERROR Shutdown ()
WEAVE_ERROR SendMessage (WeaveMessageInfo * msgInfo, PacketBuffer * msgBuf)
WEAVE_ERROR SendMessage (const IPAddress & destAddr, WeaveMessageInfo * msgInfo, PacketBuffer * msgBuf)
WEAVE_ERROR SendMessage (const IPAddress & destAddr, uint16_t destPort, InterfaceId sendIntfId, WeaveMessageInfo * msgInfo, PacketBuffer * msgBuf)
WEAVE_ERROR ResendMessage (WeaveMessageInfo * msgInfo, PacketBuffer * msgBuf)
WEAVE_ERROR ResendMessage (const IPAddress & destAddr, WeaveMessageInfo * msgInfo, PacketBuffer * msgBuf)
WEAVE_ERROR ResendMessage (const IPAddress & destAddr, uint16_t destPort, WeaveMessageInfo * msgInfo, PacketBuffer * msgBuf)
WEAVE_ERROR ResendMessage (const IPAddress & destAddr, uint16_t destPort, InterfaceId interfaceId, WeaveMessageInfo * msgInfo, PacketBuffer * msgBuf)
WEAVE_ERROR SendUDPTunneledMessage (const IPAddress & destAddr, WeaveMessageInfo * msgInfo, PacketBuffer * msgBuf)
Function to send a Tunneled packet over a local UDP tunnel.
WeaveConnection * NewConnection ()
WeaveConnectionTunnel * NewConnectionTunnel ()
void GetConnectionPoolStats (nl::Weave::System::Stats::count_t & aOutInUse)
WEAVE_ERROR CreateTunnel (WeaveConnectionTunnel ** tunPtr, WeaveConnection & conOne, WeaveConnection & conTwo, uint32_t inactivityTimeoutMS)
WEAVE_ERROR SetUnsecuredConnectionListener (ConnectionReceiveFunct newOnUnsecuredConnectionReceived, CallbackRemovedFunct newOnUnsecuredConnectionCallbacksRemoved, bool force, void * listenerState)
Set OnUnsecuredConnectionReceived callbacks. Return WEAVE_INCORRECT_STATE if callbacks already set unless force
flag set to true. If force flag is true, overwrite existing callbacks with provided values after call to
OnUnsecuredConnectionCallbackRemoved.
WEAVE_ERROR ClearUnsecuredConnectionListener (ConnectionReceiveFunct oldOnUnsecuredConnectionReceived, CallbackRemovedFunct newOnUnsecuredConnectionCallbacksRemoved)
Clear OnUnsecuredConnectionReceived and OnUnsecuredConnectionCallbackRemoved as requested by current
callback owner, using function pointer args as proof of identification.
WEAVE_ERROR DecodeHeader (PacketBuffer * msgBuf, WeaveMessageInfo * msgInfo, uint8_t ** payloadStart)
WEAVE_ERROR ReEncodeMessage (PacketBuffer * buf)
WEAVE_ERROR EncodeMessage (WeaveMessageInfo * msgInfo, PacketBuffer * msgBuf, WeaveConnection * con, uint16_t maxLen, uint16_t reserve)
WEAVE_ERROR EncodeMessage (const IPAddress & destAddr, uint16_t destPort, InterfaceId sendIntId, WeaveMessageInfo * msgInfo, PacketBuffer * payload)
WEAVE_ERROR RefreshEndpoints ()
WEAVE_ERROR CloseEndpoints ()
bool IPv4ListenEnabled ()
Check if the WeaveMessageLayer is configured to listen for inbound communications
over IPv4.
Defined at line 850 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveMessageLayer.h
bool IPv6ListenEnabled ()
Check if the WeaveMessageLayer is configured to listen for inbound communications
over IPv4.
Defined at line 870 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveMessageLayer.h
bool TCPListenEnabled ()
Check if the WeaveMessageLayer is configured to listen for inbound TCP connections.
Defined at line 884 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveMessageLayer.h
void SetTCPListenEnabled (bool val)
Enable or disable listening for inbound TCP connections in the WeaveMessageLayer.
NOTE:
must be called after the TCP listening state is changed.
Defined at line 894 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveMessageLayer.h
bool UDPListenEnabled ()
Check if the WeaveMessageLayer is configured to listen for inbound UDP messages.
Defined at line 902 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveMessageLayer.h
void SetUDPListenEnabled (bool val)
Enable or disable listening for inbound UDP messages in the WeaveMessageLayer.
NOTE:
must be called after the UDP listening state is changed.
Defined at line 912 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveMessageLayer.h
bool UnsecuredListenEnabled ()
Check if unsecured listening is enabled.
Defined at line 947 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveMessageLayer.h
bool EphemeralUDPPortEnabled ()
Check if locally initiated Weave UDP exchanges should be sent from an ephemeral
UDP source port.
Defined at line 921 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveMessageLayer.h
bool IsBoundToLocalIPv4Address ()
Check if the WeaveMessageLayer is bound to a local IPv4 address.
Defined at line 955 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveMessageLayer.h
bool IsBoundToLocalIPv6Address ()
Check if the WeaveMessageLayer is bound to a local IPv6 address.
Defined at line 967 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveMessageLayer.h
void SetSignalMessageLayerActivityChanged (MessageLayerActivityChangeHandlerFunct messageLayerActivityChangeHandler)
bool IsMessageLayerActive ()
uint32_t GetMaxWeavePayloadSize (const PacketBuffer * msgBuf, bool isUDP, uint32_t udpMTU)
void GetPeerDescription (char * buf, size_t bufSize, uint64_t nodeId, const IPAddress * addr, uint16_t port, InterfaceId interfaceId, const WeaveConnection * con)
void GetPeerDescription (char * buf, size_t bufSize, const WeaveMessageInfo * msgInfo)
Enumerations
enum State
| Name | Value |
|---|---|
| kState_NotInitialized | 0 |
| kState_Initializing | 1 |
| kState_Initialized | 2 |
The state of the WeaveMessageLayer.
Defined at line 537 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveMessageLayer.h
Records
Friends
class WeaveFabricState
class ExchangeContext
class WeaveExchangeManager
class WeaveConnection
class WeaveMessageLayerTestObject