NAP
Public Member Functions | Public Attributes | List of all members
SecureWebSocketClientEndPoint Class Reference

#include <websocketclientendpoint.h>

Public Member Functions

bool start (nap::utility::ErrorState &error) override
 
- Public Member Functions inherited from WebSocketClientEndPointSetup< wspp::ConfigTLS >
virtual bool init (utility::ErrorState &errorState) override
 
virtual void stop () override
 
bool start (nap::utility::ErrorState &error) override
 
bool send (const WebSocketConnection &connection, const std::string &message, EWebSocketOPCode code, nap::utility::ErrorState &error) override
 
bool send (const WebSocketConnection &connection, void const *payload, int length, EWebSocketOPCode code, nap::utility::ErrorState &error) override
 
- Public Member Functions inherited from Resource
 Resource ()
 
- Public Member Functions inherited from Object
 Object ()
 
virtual ~Object ()
 
virtual void onDestroy ()
 
 Object (Object &)=delete
 
Objectoperator= (const Object &)=delete
 
 Object (Object &&)=delete
 
Objectoperator= (Object &&)=delete
 

Public Attributes

std::string mCertificateChainFile
 Property: "CertificateChainFile" path to the certificate chain file. More...
 
std::string mHostName
 Property: "HostName" host name to verify against the certificate. More...
 
- Public Attributes inherited from IWebSocketClientEndPoint
bool mLogConnectionUpdates = true
 Property: "LogConnectionUpdates" if client / server connection information is logged to the console. More...
 
EWebSocketLogLevel mLibraryLogLevel = EWebSocketLogLevel::Warning
 Property: "LibraryLogLevel" library related equal to or higher than requested are logged. More...
 
- Public Attributes inherited from Object
std::string mID
 Property: 'mID' unique name of the object. Used as an identifier by the system. More...
 

Additional Inherited Members

- Static Public Member Functions inherited from Object
static bool isIDProperty (rtti::Instance &object, const rtti::Property &property)
 
- Protected Member Functions inherited from WebSocketClientEndPointSetup< wspp::ConfigTLS >
void run ()
 
bool registerClient (IWebSocketClient &client, utility::ErrorState &error) override
 
void unregisterClient (const IWebSocketClient &client) override
 
- Protected Attributes inherited from WebSocketClientEndPointSetup< wspp::ConfigTLS >
uint32 mLogLevel
 Converted library log level. More...
 
uint32 mAccessLogLevel
 Log client / server connection data. More...
 
bool mRunning
 If the client connection to the server is open. More...
 
std::future< void > mClientTask
 The client server thread. More...
 
std::vector< std::unique_ptr< WebSocketClientWrapper< wspp::ConfigTLS > > > mClients
 All unique client connections. More...
 
websocketpp::client< wspp::ConfigTLSmEndPoint
 websocketpp client end point More...
 

Description

Secured client end point connection.

Inheritance diagram for SecureWebSocketClientEndPoint:
[legend]
Collaboration diagram for SecureWebSocketClientEndPoint:
[legend]

Member Function Documentation

◆ start()

bool start ( nap::utility::ErrorState error)
overridevirtual

Starts the endpoint. This is a non-blocking call. New connections are accepted. Connection updates and messages are received in a background thread.

Parameters
errorcontains the error if the endpoint can't be started.
Returns
if the endpoint started.

Reimplemented from Device.

Member Data Documentation

◆ mCertificateChainFile

std::string mCertificateChainFile

Property: "CertificateChainFile" path to the certificate chain file.

◆ mHostName

std::string mHostName

Property: "HostName" host name to verify against the certificate.