μHAL (v2.7.9)
Part of the IPbus software repository
Public Types | Public Member Functions | Private Attributes | List of all members
uhal::TimeIntervalStats Class Reference

#include <uhal/utilities/TimeIntervalStats.hpp>

Public Types

typedef boost::chrono::steady_clock Clock_t
 

Public Member Functions

 TimeIntervalStats ()
 
 ~TimeIntervalStats ()
 
size_t size () const
 
const Clock_t::duration & min () const
 
const Clock_t::duration & max () const
 
Clock_t::duration mean () const
 
const std::queue< Clock_t::duration > & getLatestMeasurements () const
 
void add (const Clock_t::time_point &aT1, const Clock_t::time_point &aT2)
 
void clear ()
 

Private Attributes

std::queue< Clock_t::duration > mLatestMeasurements
 
Clock_t::duration mMin
 
Clock_t::duration mMax
 
Clock_t::duration mSum
 
size_t nMeasurements
 

Detailed Description

Definition at line 15 of file TimeIntervalStats.hpp.

Member Typedef Documentation

◆ Clock_t

typedef boost::chrono::steady_clock uhal::TimeIntervalStats::Clock_t

Definition at line 17 of file TimeIntervalStats.hpp.

Constructor & Destructor Documentation

◆ TimeIntervalStats()

uhal::TimeIntervalStats::TimeIntervalStats ( )

Definition at line 15 of file TimeIntervalStats.cpp.

◆ ~TimeIntervalStats()

uhal::TimeIntervalStats::~TimeIntervalStats ( )

Definition at line 21 of file TimeIntervalStats.cpp.

Member Function Documentation

◆ add()

void uhal::TimeIntervalStats::add ( const Clock_t::time_point &  aT1,
const Clock_t::time_point &  aT2 
)

Definition at line 56 of file TimeIntervalStats.cpp.

References mLatestMeasurements, mMax, mMin, mSum, and nMeasurements.

◆ clear()

void uhal::TimeIntervalStats::clear ( )

Definition at line 74 of file TimeIntervalStats.cpp.

References mLatestMeasurements, and nMeasurements.

◆ getLatestMeasurements()

const std::queue< TimeIntervalStats::Clock_t::duration > & uhal::TimeIntervalStats::getLatestMeasurements ( ) const

Definition at line 50 of file TimeIntervalStats.cpp.

References mLatestMeasurements.

Referenced by uhal::operator<<().

◆ max()

const TimeIntervalStats::Clock_t::duration & uhal::TimeIntervalStats::max ( ) const

Definition at line 38 of file TimeIntervalStats.cpp.

References mMax.

Referenced by uhal::operator<<().

◆ mean()

TimeIntervalStats::Clock_t::duration uhal::TimeIntervalStats::mean ( ) const

Definition at line 44 of file TimeIntervalStats.cpp.

References mSum, and nMeasurements.

Referenced by uhal::operator<<().

◆ min()

const TimeIntervalStats::Clock_t::duration & uhal::TimeIntervalStats::min ( ) const

Definition at line 32 of file TimeIntervalStats.cpp.

References mMin.

Referenced by uhal::operator<<().

◆ size()

size_t uhal::TimeIntervalStats::size ( ) const

Definition at line 26 of file TimeIntervalStats.cpp.

References nMeasurements.

Referenced by uhal::operator<<().

Member Data Documentation

◆ mLatestMeasurements

std::queue<Clock_t::duration> uhal::TimeIntervalStats::mLatestMeasurements
private

Definition at line 37 of file TimeIntervalStats.hpp.

Referenced by add(), clear(), and getLatestMeasurements().

◆ mMax

Clock_t::duration uhal::TimeIntervalStats::mMax
private

Definition at line 40 of file TimeIntervalStats.hpp.

Referenced by add(), and max().

◆ mMin

Clock_t::duration uhal::TimeIntervalStats::mMin
private

Definition at line 39 of file TimeIntervalStats.hpp.

Referenced by add(), and min().

◆ mSum

Clock_t::duration uhal::TimeIntervalStats::mSum
private

Definition at line 41 of file TimeIntervalStats.hpp.

Referenced by add(), and mean().

◆ nMeasurements

size_t uhal::TimeIntervalStats::nMeasurements
private

Definition at line 43 of file TimeIntervalStats.hpp.

Referenced by add(), clear(), mean(), and size().


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