mirror of
https://github.com/eclipse/paho.mqtt-sn.embedded-c.git
synced 2025-12-16 08:56:51 +01:00
Add ClientPool
Clients are created and kept in the pool at first. ClientList gets a free client from the pool. Signed-off-by: tomoaki <tomoaki@tomy-tech.com>
This commit is contained in:
@@ -32,14 +32,15 @@ char* currentDateTime(void);
|
||||
Class Client
|
||||
=====================================*/
|
||||
static const char* theClientStatus[] =
|
||||
{ "Disconnected", "TryConnecting", "Connecting", "Active", "Asleep", "Awake",
|
||||
{ "InPool", "Disconnected", "TryConnecting", "Connecting", "Active", "Asleep",
|
||||
"Awake",
|
||||
"Lost" };
|
||||
|
||||
Client::Client(bool secure)
|
||||
{
|
||||
_packetId = 0;
|
||||
_snMsgId = 0;
|
||||
_status = Cstat_Disconnected;
|
||||
_status = Cstat_Free;
|
||||
_keepAliveMsec = 0;
|
||||
_topics = new Topics();
|
||||
_clientId = nullptr;
|
||||
|
||||
Reference in New Issue
Block a user