gramods
Classes | Public Member Functions | Static Public Attributes | List of all members
gramods::gmTrack::TimeSampleButtonsTracker Class Reference

This buttons tracker reports button states as specified in the samples of the node. More...

#include <TimeSampleButtonsTracker.hh>

Inheritance diagram for gramods::gmTrack::TimeSampleButtonsTracker:
Inheritance graph
[legend]
Collaboration diagram for gramods::gmTrack::TimeSampleButtonsTracker:
Collaboration graph
[legend]

Classes

struct  Impl
 

Public Member Functions

void addTime (double t)
 Adds a time sample in seconds, from the start of the program. More...
 
void addButtons (size_t b)
 Adds a button states sample as an integer where the least significant bit represents the main button. More...
 
bool getButtons (ButtonsSample &b) override
 Replaces the contents of p with button data. More...
 
- Public Member Functions inherited from gramods::gmTrack::ButtonsTracker
virtual std::string getDefaultKey () override
 Returns the default key, in Configuration, for the Object. More...
 
- Public Member Functions inherited from gramods::gmCore::Object
 Object ()
 Initializes internal data. More...
 
virtual ~Object ()
 Cleaning up internal data. More...
 
virtual void initialize ()
 Called to initialize the Object. More...
 
virtual void accept (Visitor *visitor)
 Calls the visitors apply method with this as argument. More...
 
virtual void traverse (Visitor *visitor)
 Calls the child Object's accept method, if such exist. More...
 
bool isInitialized ()
 Returns true if the Object is initialized. More...
 

Static Public Attributes

static gramods::gmCore::OFactory::OFactoryInformation _gm_ofi
 

Additional Inherited Members

- Public Types inherited from gramods::gmTrack::ButtonsTracker
typedef std::chrono::steady_clock clock
 

Detailed Description

This buttons tracker reports button states as specified in the samples of the node.

Member Function Documentation

◆ addButtons()

void gramods::gmTrack::TimeSampleButtonsTracker::addButtons ( size_t  b)

Adds a button states sample as an integer where the least significant bit represents the main button.

XML-attribute: buttons

◆ addTime()

void gramods::gmTrack::TimeSampleButtonsTracker::addTime ( double  t)

Adds a time sample in seconds, from the start of the program.

There must be at least two time samples as well as an equal amount of time samples and amount of button samples.

XML-attribute: time

◆ getButtons()

bool gramods::gmTrack::TimeSampleButtonsTracker::getButtons ( ButtonsSample b)
overridevirtual

Replaces the contents of p with button data.

Implements gramods::gmTrack::ButtonsTracker.


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