Zth (libzth)

Classes

class  zth::TimeInterval
 Convenient wrapper around struct timespec that contains a time interval. More...
 
class  zth::Timestamp
 Convenient wrapper around struct timespec that contains an absolute timestamp. More...
 

Functions

constexpr TimeInterval zth::operator""_s (unsigned long long int x) noexcept
 Define literals like 123_s, which is a zth::TimeInterval of 123 seconds. More...
 
constexpr TimeInterval zth::operator""_ms (unsigned long long int x) noexcept
 Define literals like 123_ms, which is a zth::TimeInterval of 123 milliseconds. More...
 
constexpr TimeInterval zth::operator""_us (unsigned long long int x) noexcept
 Define literals like 123_us, which is a zth::TimeInterval of 123 microseconds. More...
 
TimeInterval zth::operator""_s (long double x)
 Define literals like 12.3_s, which is a zth::TimeInterval of 12.3 seconds. More...
 

Detailed Description

Function Documentation

◆ operator""_ms()

constexpr TimeInterval zth::operator""_ms ( unsigned long long int  x)
inlineconstexprnoexcept

Define literals like 123_ms, which is a zth::TimeInterval of 123 milliseconds.

You may want to put using zth::operator""_ms; in your code to simplify using it.

Definition at line 493 of file time.h.

◆ operator""_s() [1/2]

TimeInterval zth::operator""_s ( long double  x)
inline

Define literals like 12.3_s, which is a zth::TimeInterval of 12.3 seconds.

You may want to put using zth::operator""_s; in your code to simplify using it.

Definition at line 517 of file time.h.

◆ operator""_s() [2/2]

constexpr TimeInterval zth::operator""_s ( unsigned long long int  x)
inlineconstexprnoexcept

Define literals like 123_s, which is a zth::TimeInterval of 123 seconds.

You may want to put using zth::operator""_s; in your code to simplify using it.

Definition at line 480 of file time.h.

◆ operator""_us()

constexpr TimeInterval zth::operator""_us ( unsigned long long int  x)
inlineconstexprnoexcept

Define literals like 123_us, which is a zth::TimeInterval of 123 microseconds.

You may want to put using zth::operator""_us; in your code to simplify using it.

Definition at line 505 of file time.h.