Name
tick_count::interval_t Class — Class for relative wall-clock time.
Synopsis
#include "tbb/tick_count.h" class tick_count::interval_t;
Description
A tick_count::interval_t represents relative wall-clock time or duration.
Members provide for the accumulation and reduction of intervals by other interval_t values, and for the conversion of interval_t values into seconds.
Members
namespace tbb {
class tick_count::interval_t {
public:
interval_t();
double seconds() const;
interval_t operator+=( const interval_t& i );
interval_t operator-=( const interval_t& i );
};
tick_count::interval_t operator+( const tick_count::interval_t& i,
const tick_count::interval_t& j );
tick_count::interval_t operator-( const tick_count::interval_t& i,
const tick_count::interval_t& j );
} // tbb-
interval_t() Effects: constructs an
interval_trepresenting a zero time duration.-
doubleseconds()const Returns: a time interval measured in seconds (can have noninteger values).
-
interval_t operator+=(const interval_t&i) Effects:
*this = *this+i.Returns: a reference to
*thisafter the addition.-
interval_t operator-=(const interval_t&i) Effects:
*this = *this -i.Returns: a reference to
*thisafter the subtraction.-
interval_t operator+(constinterval_t&i,const interval_t&j) Returns: an
interval_trepresenting the sum of intervalsiandj.-
interval_t operator-(constinterval_t&i,const interval_t&j) Returns: an
interval_trepresenting the difference between intervalsiandj.
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access