 |
Diarkis C++Client Library API Document
|
Go to the documentation of this file.
8 #include "logging/LoggerFactory.h"
46 virtual void Setup(
const std::shared_ptr<LoggerFactory>& loggerFactory);
60 bool Connect(
const char* endpoint,
const char* clientKey,
const struct AuthInfo* auth);
68 bool Connect(
const std::string& endpoint,
const std::string& clientKey,
const struct AuthInfo* auth);
88 bool Connect(
const std::string& endpoint,
89 const std::string& clientKey,
90 const std::vector<uint8_t>& sid,
91 const std::vector<uint8_t>& key,
92 const std::vector<uint8_t>& iv,
93 const std::vector<uint8_t>& mackey);
125 void SetSchedulerAddNotifyEvent(std::function<
void()> notifyEventFunc);
141 std::shared_ptr<IDiarkisTcp>
Get();
153 bool SendHeartbeat(
void);
163 bool SendMigrate(
void);
180 virtual void OnDisconnect(
bool isReconnect);
188 virtual void OnOffline();
212 virtual void OnHeartbeat();
228 std::shared_ptr<IDiarkisTcp>
tcp_;
Base class that wraps the IDiarkisTcp class for easy use of TCP functionality.
Definition: DiarkisTcpBase.h:17
DiarkisTransportType
Protocol type.
Definition: transport.h:27
bool bOffline_
Whether the server is getting ready to shut down.
Definition: DiarkisTcpBase.h:260
std::function< void()> schedulerAddNotifyEventFunc_
Callback function called when TCP related events are added.
Definition: DiarkisTcpBase.h:252
std::shared_ptr< IDiarkisLogger > logger_
Pointer to IDiarkisLogger class.
Definition: DiarkisTcpBase.h:236
Arguments of the callback events when connecting to the server.
Definition: eventArgs.h:153
Argument of the callback event called when a UDP or TCP Response is received.
Definition: eventArgs.h:1365
Diarkis::StdVector< std::function< void()> > eventUnsubscriptions_
List of lambda functions.
Definition: DiarkisTcpBase.h:244
#define DIARKIS_API
Definition: common.h:47
std::shared_ptr< IDiarkisTcp > tcp_
Pointer to IDiarkisTcp class.
Definition: DiarkisTcpBase.h:228
Argument of the callback event called when a UDP or TCP Push is received.
Definition: eventArgs.h:1316