SatCat5
satcat5::poll::Always Class Referenceabstract

Detailed Description

An "Always" object is polled whenever service() is called.

SatCat5 event-loop concepts.

Use this type sparingly, to avoid excessive CPU loading. To receive Always callbacks, derive a child class and override "poll_always()".

Definition at line 96 of file polling.h.

#include <polling.h>

Inheritance diagram for satcat5::poll::Always:
[legend]
Collaboration diagram for satcat5::poll::Always:
[legend]

Public Member Functions

virtual void poll_always ()=0
 Child class MUST override this method. More...
 

Static Public Member Functions

static unsigned count_always ()
 Count active objects of this type.
 

Protected Member Functions

 Always (bool auto_register=true)
 Registers this pollable object unless auto_register = false. More...
 
void poll_register ()
 Register this pollable object, called by the constructor.
 
void poll_unregister ()
 Unregister this pollable object, called by the destructor.
 

Private Attributes

satcat5::poll::Alwaysm_next
 

Friends

void satcat5::poll::service ()
 

Constructor & Destructor Documentation

◆ Always()

satcat5::poll::Always::Always ( bool  auto_register = true)
explicitprotected

Registers this pollable object unless auto_register = false.

(Only children should create or destroy the base class.)

Definition at line 168 of file polling.cc.

Member Function Documentation

◆ poll_always()

virtual void satcat5::poll::Always::poll_always ( )
pure virtual

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