Dynamical system model
Loading...
Searching...
No Matches
dsm::Counter Class Reference

The Counter class contains two counters to count input and output. More...

#include <Sensors.hpp>

Inheritance diagram for dsm::Counter:
dsm::SpireStreet dsm::StochasticSpireStreet

Public Member Functions

void increaseInputCounter ()
 Increase the input counter by one.
 
void increaseOutputCounter ()
 Increase the output counter by one.
 
int inputCounts (bool reset=true)
 Get the number of input counts registered.
 
int outputCounts (bool reset=true)
 Get the number of output counts registered.
 

Protected Attributes

std::pair< int, int > m_counters = {0, 0}
 

Detailed Description

The Counter class contains two counters to count input and output.

Member Function Documentation

◆ inputCounts()

int dsm::Counter::inputCounts ( bool reset = true)

Get the number of input counts registered.

Parameters
resetIf true, the counter is reset to 0. Default is true

◆ outputCounts()

int dsm::Counter::outputCounts ( bool reset = true)

Get the number of output counts registered.

Parameters
resetIf true, the counter is reset to 0. Default is true

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