class BdxNode

Defined at line 67 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Profiles/bulk-data-transfer/Development/BDXNode.h

In order to make life easier for users of the bulk data transfer

protocol, we provide this server. The word "server" is chosen here

even though it can act both as a client or as a server. While the client

is expected to only handle one ongoing transfer at a time, the server may

handle many. Thus, configuring the number of BDXTransfer contained within

the server to 1 would make this into a 'client'.

Note that the server defers to the BdxProtocol class for handling BDX

messages and the proper responses and maintenance of the BDXTransfer state.

Thus, this class is mostly responsible for managing these transfers and their

Weave-related resources.

The main points of entry for users of the BDX Protocol are to call InitBdxSend(),

InitBdxReceive(), AwaitBdxReceiveInit(), or AwaitBdxSendInit() after creating and initializing the server

(init must be properly called before the server can be used)

or obtaining a reference to an existing one. Note that in order to use the first

two aforementioned methods, the user must first obtain and configure a BDXTransfer

object using NewTransfer(). This allows them the opportunity to configure the

callbacks and various parameters affecting the Transfer appropriately before

initializing it.

TODO: to lower the code footprint for a client application on a highly-constrained

device, one might consider wrapping #ifdefs around AwaitBdxSendInit, AwaitBdxReceiveInit,

HandleReceiveInit, and HandleSendInit to disable those features and entirely remove

their code for a device not meant to support them.

Public Methods

void BdxNode ()

Default constructor that sets all members to NULL. Don't try to do anything

with the server until you've at least called init().

WEAVE_ERROR Init (WeaveExchangeManager * anExchangeMgr)
WEAVE_ERROR Shutdown ()
WEAVE_ERROR NewTransfer (Binding * aBinding, BDXHandlers aBDXHandlers, ReferencedString & aFileDesignator, void * anAppState, BDXTransfer *& aXfer)
WEAVE_ERROR NewTransfer (WeaveConnection * aCon, BDXHandlers aBDXHandlers, ReferencedString & aFileDesignator, void * anAppState, BDXTransfer *& aXfer)
void ShutdownTransfer (BDXTransfer * aXfer)
void AllowBdxTransferToRun (bool aEnable)
bool CanBdxTransferRun ()
bool IsInitialized ()
WEAVE_ERROR InitBdxReceive (BDXTransfer & aXfer, bool aICanDrive, bool aUCanDrive, bool aAsyncOk, ReferencedTLVData * aMetaData)
WEAVE_ERROR InitBdxSend (BDXTransfer & aXfer, bool aICanDrive, bool aUCanDrive, bool aAsyncOk, ReferencedTLVData * aMetaData)
WEAVE_ERROR InitBdxSend (BDXTransfer & aXfer, bool aICanDrive, bool aUCanDrive, bool aAsyncOk, SendInit::MetaDataTLVWriteCallback aMetaDataWriteCallback, void * aMetaDataAppState)
WEAVE_ERROR AwaitBdxReceiveInit (ReceiveInitHandler aReceiveInitHandler)
WEAVE_ERROR AwaitBdxSendInit (SendInitHandler aSendInitHandler)
void HandleSendInit (ExchangeContext * anEc, const IPPacketInfo * aPktInfo, const WeaveMessageInfo * aWeaveMsgInfo, uint32_t aProfileId, uint8_t aMessageType, PacketBuffer * aPacketBuffer)
void HandleReceiveInit (ExchangeContext * anEc, const IPPacketInfo * aPktInfo, const WeaveMessageInfo * aWeaveMsgInfo, uint32_t aProfileId, uint8_t aMessageType, PacketBuffer * aPacketBuffer)