Base class implementing sample RPC functionality.
More...
#include <DiarkisRpcBase.h>
|
| | DiarkisRpcBase () |
| | DiarkisRpcBase constructor. More...
|
| |
| virtual | ~DiarkisRpcBase () |
| | DiarkisRpcBase destructor. More...
|
| |
| virtual void | SetupRpc (const char *uid, const std::shared_ptr< IDiarkisRoom > &room, const std::shared_ptr< LoggerFactory > &loggerFactory) |
| | Set up RPC. More...
|
| |
| virtual void | SetupRpc (const std::string &uid, const std::shared_ptr< IDiarkisRoom > &room, const std::shared_ptr< LoggerFactory > &loggerFactory) |
| | Same as SetupRpc() More...
|
| |
| virtual bool | RPCAll (uint32_t rpcID, const uint8_t *payload, size_t payloadSize, bool reliable=true) |
| | Call the RPCs of all participants in the room. More...
|
| |
| virtual bool | RPCAll (uint32_t rpcID, const std::vector< uint8_t > &payload, bool reliable=true) |
| | Same as RPCAll() More...
|
| |
| virtual bool | RPCMany (uint32_t rpcID, const char **memberIDs, size_t memberIDsCount, const uint8_t *payload, size_t payloadSize, bool reliable=true) |
| | Calls the RPC of any member participating in the room. More...
|
| |
| virtual bool | RPCMany (uint32_t rpcID, const std::vector< std::string > &memberIDs, const std::vector< uint8_t > &payload, bool reliable=true) |
| | Same as RPCMany() More...
|
| |
| virtual bool | RPCOne (uint32_t rpcID, const char *userID, const uint8_t *payload, size_t payloadSize, bool reliable=true) |
| | Calls the RPC of a specific member participating in the room. More...
|
| |
| virtual bool | RPCOne (uint32_t rpcID, const std::string &userID, const std::vector< uint8_t > &payload, bool reliable=true) |
| | Same as RPCOne() More...
|
| |
Base class implementing sample RPC functionality.
◆ DiarkisRpcBase()
| DiarkisRpcBase::DiarkisRpcBase |
( |
| ) |
|
◆ ~DiarkisRpcBase()
| DiarkisRpcBase::~DiarkisRpcBase |
( |
| ) |
|
|
virtual |
◆ SetupRpc() [1/2]
| void DiarkisRpcBase::SetupRpc |
( |
const char * |
uid, |
|
|
const std::shared_ptr< IDiarkisRoom > & |
room, |
|
|
const std::shared_ptr< LoggerFactory > & |
loggerFactory |
|
) |
| |
|
virtual |
Set up RPC.
Register loggers and callback functions.
- Parameters
-
| [in] | uid | your user ID |
| [in] | room | Pointer to IDiarkisRoom class |
| [in] | loggerFactory | Log for client library |
◆ SetupRpc() [2/2]
| void DiarkisRpcBase::SetupRpc |
( |
const std::string & |
uid, |
|
|
const std::shared_ptr< IDiarkisRoom > & |
room, |
|
|
const std::shared_ptr< LoggerFactory > & |
loggerFactory |
|
) |
| |
|
virtual |
◆ RPCAll() [1/2]
| bool DiarkisRpcBase::RPCAll |
( |
uint32_t |
rpcID, |
|
|
const uint8_t * |
payload, |
|
|
size_t |
payloadSize, |
|
|
bool |
reliable = true |
|
) |
| |
|
virtual |
Call the RPCs of all participants in the room.
- Parameters
-
| [in] | rpcID | ID of the RPC to be called |
| [in] | payload | Data to be sent |
| [in] | payloadSize | Length of the payload |
| [in] | reliable | Determines whether to send over reliable communication (RUDP). |
◆ RPCAll() [2/2]
| bool DiarkisRpcBase::RPCAll |
( |
uint32_t |
rpcID, |
|
|
const std::vector< uint8_t > & |
payload, |
|
|
bool |
reliable = true |
|
) |
| |
|
virtual |
◆ RPCMany() [1/2]
| bool DiarkisRpcBase::RPCMany |
( |
uint32_t |
rpcID, |
|
|
const char ** |
memberIDs, |
|
|
size_t |
memberIDsCount, |
|
|
const uint8_t * |
payload, |
|
|
size_t |
payloadSize, |
|
|
bool |
reliable = true |
|
) |
| |
|
virtual |
Calls the RPC of any member participating in the room.
- Parameters
-
| [in] | rpcID | ID of the RPC to call |
| [in] | memberIDs | List of user IDs of members to call |
| [in] | memberIDsCount | Number of member IDs |
| [in] | payload | Data to be sent |
| [in] | payloadSize | Length of the payload |
| [in] | reliable | Determines whether to send over reliable communication (RUDP). |
◆ RPCMany() [2/2]
| bool DiarkisRpcBase::RPCMany |
( |
uint32_t |
rpcID, |
|
|
const std::vector< std::string > & |
memberIDs, |
|
|
const std::vector< uint8_t > & |
payload, |
|
|
bool |
reliable = true |
|
) |
| |
|
virtual |
◆ RPCOne() [1/2]
| bool DiarkisRpcBase::RPCOne |
( |
uint32_t |
rpcID, |
|
|
const char * |
userID, |
|
|
const uint8_t * |
payload, |
|
|
size_t |
payloadSize, |
|
|
bool |
reliable = true |
|
) |
| |
|
virtual |
Calls the RPC of a specific member participating in the room.
- Parameters
-
| [in] | rpcID | ID of the RPC to call |
| [in] | userID | Target user ID |
| [in] | payload | Data to be sent |
| [in] | payloadSize | Length of the payload |
| [in] | reliable | Determines whether to send over reliable communication (RUDP). |
◆ RPCOne() [2/2]
| bool DiarkisRpcBase::RPCOne |
( |
uint32_t |
rpcID, |
|
|
const std::string & |
userID, |
|
|
const std::vector< uint8_t > & |
payload, |
|
|
bool |
reliable = true |
|
) |
| |
|
virtual |
◆ rpc_
Pointer to IDiarkisRPC class.
◆ room_
Pointer to IDiarkisRoom class.
◆ logger_
Pointer to IDiarkisLogger.
◆ ownUid_
◆ eventUnsubscriptions_
The documentation for this class was generated from the following files: