Cypress Bluetooth Mesh Gateway

Description

Defines a CloudClient base class.

Inheritance diagram for CloudClient:
AWSMQTTClient

Public Member Functions

virtual ~CloudClient ()
 CloudClient Destructor.
 
 CloudClient (NetworkInterface &iface)
 CloudClient constructor. More...
 
 CloudClient (NetworkInterface &iface, const char *name, ClientType cli_type, ClientSecurity *security)
 CloudClient constructor. More...
 
void set_name (const char *name)
 Sets CloudClient name. More...
 
const char * get_name (void)
 Gets CloudClient name. More...
 
ClientType get_type (void)
 Returns CloudClient Object type. More...
 
int isMQTTClient (void)
 Returns 1 if CloudClient is of MQTT type, 0 otherwise.
 
NetworkInterface & get_network_instance (void)
 Returns NetworkInterface Instance in use by the client.
 
virtual cy_rslt_t initialize (void)=0
 Initialize Cloud-Client.
 
virtual void shutdown (void)=0
 Shut-down Cloud-Client.
 
virtual cy_rslt_t connect (ClientConnectionParams *params)=0
 Connect to the server as specified in connection-parameters.
 
virtual cy_rslt_t disconnect (void)=0
 Disconnect from the server.
 

Protected Attributes

NetworkInterface & network
 Network Interface to be used by the cloud-client.
 
const char * _client_name
 user-defined name for this device/client
 
ClientSecurity_security
 Security params to be used by this cloud-client.
 
enum ClientType _type
 Client type.
 

Constructor & Destructor Documentation

◆ CloudClient() [1/2]

CloudClient::CloudClient ( NetworkInterface &  iface)
inline

CloudClient constructor.

Parameters
[in]iface: Network Interface instance to use

By default, it assumes to be an AWS IoT Client.

◆ CloudClient() [2/2]

CloudClient::CloudClient ( NetworkInterface &  iface,
const char *  name,
ClientType  cli_type,
ClientSecurity security 
)
inline

CloudClient constructor.

Parameters
[in]iface: Network Interface instance to use
[in]nameCloudClient name to use
[in]cli_typeCloud Client type
[in]securityClient Security Object - defines security attributes to be used for the client

Member Function Documentation

◆ set_name()

void CloudClient::set_name ( const char *  name)
inline

Sets CloudClient name.

Parameters
[in]nameCloudClient name to use

◆ get_name()

const char* CloudClient::get_name ( void  )
inline

Gets CloudClient name.

Returns
Null-terminated Cloud-client name

◆ get_type()

ClientType CloudClient::get_type ( void  )
inline

Returns CloudClient Object type.

Returns
ClientType