Open Lighting Architecture  0.9.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | List of all members
ola::network::HealthCheckedConnection Class Reference

Detailed Description

An class that provides health checking for a connection. The subclasses implement the SendHeartbeat and HeartbeatTimeout methods.

Public Member Functions

 HealthCheckedConnection (ola::thread::SchedulerInterface *scheduler, const ola::TimeInterval timeout_interval)
bool Setup ()
virtual void SendHeartbeat ()=0
void HeartbeatSent ()
void HeartbeatReceived ()
void PauseTimer ()
void ResumeTimer ()
virtual void HeartbeatTimeout ()=0

Member Function Documentation

void ola::network::HealthCheckedConnection::HeartbeatReceived ( )

Reset the RX timer

void ola::network::HealthCheckedConnection::HeartbeatSent ( )

Call this when a heartbeat is piggybacked on another message. This prevents sending heatbeats unless necessary.

Reset the send timer

virtual void ola::network::HealthCheckedConnection::HeartbeatTimeout ( )
pure virtual

This is called when we don't receive a health check within the interval.

void ola::network::HealthCheckedConnection::PauseTimer ( )

Pause the receive timer

void ola::network::HealthCheckedConnection::ResumeTimer ( )

Resume the health check timer. Call this when reading is resumed.

Resume the receive timer

bool ola::network::HealthCheckedConnection::Setup ( )

Setup the health checked channel


The documentation for this class was generated from the following files: