Nix (Dev) 3.5.10
dev - 3.5.10 - 1af9301
|
#include <ApiEventLoggerCommunicationProtocol.hpp>
Classes | |
struct | EventsApi |
Public Member Functions | |
ApiEventLoggerCommunicationProtocol (const std::shared_ptr< iv::comms::ICommunicationDriver > &driver, const std::shared_ptr< iv::model::comms::NetworkData > &networkData, const std::weak_ptr< iv::channels::AbstractChannel > &heartbeatChannel, const std::weak_ptr< iv::diamar::AppFailuresLoggerManager > &appFailuresLoggerManager, bool sendToCloud) | |
~ApiEventLoggerCommunicationProtocol () override=default | |
bool | sendValues () override |
Send all registered messages to the API. | |
bool | isOnline () override |
iv::comms::api::ApiResponse | getValues (const IApiQueryParamsBuilder &queryParams) const override |
Get values from the API. | |
iv::comms::api::ApiDeleteResponse | deleteValues (const IApiQueryParamsBuilder &queryParams) const override |
Delete values from the API. | |
void | registerValue (const std::shared_ptr< iv::comms::api::ILoggerMessage > &message) override |
Registers an API message without blocking the thread. | |
iv::comms::api::ApiPingResponse | ping () const |
bool | wipe () const |
bool | isEnabled () const |
Protected Attributes | |
std::shared_ptr< iv::comms::ICommunicationDriver > | m_driver |
bool | m_sendToCloud {false} |
bool | m_isEnabled {true} |
std::shared_ptr< iv::model::comms::NetworkData > | m_networkData |
std::weak_ptr< iv::comms::api::ApiCommunicationDriver > | m_apiDriver |
std::weak_ptr< iv::channels::AbstractChannel > | m_heartbeatChannel |
std::weak_ptr< iv::diamar::AppFailuresLoggerManager > | m_appFailuresLoggerManager |
Private Attributes | |
std::unique_ptr< iv::containers::CircularQueue< std::shared_ptr< iv::comms::api::eventLogger::EventLoggerMessage >, m_sendQueueSize > > | m_sendQueue |
Static Private Attributes | |
static constexpr std::size_t | m_sendQueueSize {5000} |
iv::comms::api::eventLogger::ApiEventLoggerCommunicationProtocol::ApiEventLoggerCommunicationProtocol | ( | const std::shared_ptr< iv::comms::ICommunicationDriver > & | driver, |
const std::shared_ptr< iv::model::comms::NetworkData > & | networkData, | ||
const std::weak_ptr< iv::channels::AbstractChannel > & | heartbeatChannel, | ||
const std::weak_ptr< iv::diamar::AppFailuresLoggerManager > & | appFailuresLoggerManager, | ||
bool | sendToCloud ) |
|
overridedefault |
|
nodiscardoverridevirtual |
Delete values from the API.
queryParams |
Implements iv::comms::api::IApiCommunicationProtocol.
|
nodiscardoverridevirtual |
Get values from the API.
queryParams |
Implements iv::comms::api::IApiCommunicationProtocol.
|
nodiscardinherited |
|
nodiscardoverridevirtual |
Implements iv::comms::ICommunicationProtocol.
|
nodiscardinherited |
|
overridevirtual |
Registers an API message without blocking the thread.
message |
Implements iv::comms::api::IApiCommunicationProtocol.
|
overridevirtual |
Send all registered messages to the API.
Implements iv::comms::api::IApiCommunicationProtocol.
|
nodiscardinherited |
|
protectedinherited |
|
protectedinherited |
|
protectedinherited |
|
protectedinherited |
|
protectedinherited |
|
protectedinherited |
|
private |
|
staticconstexprprivate |
|
protectedinherited |
Boolean that determines if the API should send data to the cloud on request.