nl:: Weave:: WeaveServerBase
#include <src/lib/core/WeaveServerBase.h>
Common, base object for implementing Weave profile unsolicited responders (servers) that encapsulates validating authenticated requests and sending status reports and provides common data member storage for fabric state and an exchange manager.
Summary
Inheritance
Direct Known Subclasses:nl::Weave::Profiles::DeviceControl::DeviceControlServer
nl::Weave::Profiles::DeviceDescription::DeviceDescriptionServer
nl::Weave::Profiles::Echo_Next::WeaveEchoServer
nl::Weave::Profiles::FabricProvisioning::FabricProvisioningServer
nl::Weave::Profiles::Heartbeat::WeaveHeartbeatReceiver
nl::Weave::Profiles::NetworkProvisioning::NetworkProvisioningServer
nl::Weave::Profiles::ServiceProvisioning::ServiceProvisioningServer
nl::Weave::Profiles::TokenPairing::TokenPairingServer
nl::Weave::Profiles::Vendor::Nestlabs::DropcamLegacyPairing::DropcamLegacyPairingServer
nl::Weave::Profiles::WeaveEchoServer
Public attributes |
|
---|---|
ExchangeMgr
|
[READ ONLY] Exchange manager object
|
FabricState
|
[READ ONLY] Fabric state object
|
Public static functions |
|
---|---|
SendStatusReport(ExchangeContext *ec, uint32_t statusProfileId, uint16_t statusCode, WEAVE_ERROR sysError)
|
Send a Weave status report with default message flags to the initiator on the specified exchange containing the status code in the specified profile and system error.
|
SendStatusReport(ExchangeContext *ec, uint32_t statusProfileId, uint16_t statusCode, WEAVE_ERROR sysError, uint16_t sendFlags)
|
Send a Weave status report with the provided message flags to the initiator on the specified exchange containing the status code in the specified profile and system error.
|
Protected functions |
|
---|---|
EnforceAccessControl(ExchangeContext *ec, uint32_t msgProfileId, uint8_t msgType, const WeaveMessageInfo *msgInfo, WeaveServerDelegateBase *delegate)
|
bool
Determine whether an incoming request message to a Weave server should be accepted or discarded.
|
WeaveServerBase(void)
|
|
Public attributes
Public static functions
SendStatusReport
WEAVE_ERROR SendStatusReport( ExchangeContext *ec, uint32_t statusProfileId, uint16_t statusCode, WEAVE_ERROR sysError )
Send a Weave status report with default message flags to the initiator on the specified exchange containing the status code in the specified profile and system error.
Details | |||||||||
---|---|---|---|---|---|---|---|---|---|
Parameters |
|
SendStatusReport
WEAVE_ERROR SendStatusReport( ExchangeContext *ec, uint32_t statusProfileId, uint16_t statusCode, WEAVE_ERROR sysError, uint16_t sendFlags )
Send a Weave status report with the provided message flags to the initiator on the specified exchange containing the status code in the specified profile and system error.
Details | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Parameters |
|
Protected functions
EnforceAccessControl
bool EnforceAccessControl( ExchangeContext *ec, uint32_t msgProfileId, uint8_t msgType, const WeaveMessageInfo *msgInfo, WeaveServerDelegateBase *delegate )
Determine whether an incoming request message to a Weave server should be accepted or discarded.
This method is intended to be used by Weave server implementations to implement extensible access control policy for incoming request messages. Server implementations that rely on delegate objects should call this method early in message processing to determine whether message processing should continue.
This method calls the virtual WeaveServerDelegateBase::EnforceAccessControl() method on the supplied delegate to evaluate access control policy for the message. Weave server delegate classes, and application-specific delegates derived from the standard server classes, should override the virtual method to enforce specific access control policies.
Details | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Parameters |
|
||||||||||
Return Values |
|
WeaveServerBase
WeaveServerBase( void )