xronos-sdk 0.5.0
Xronos C++ SDK
Loading...
Searching...
No Matches
time.hh File Reference
#include <chrono>
#include <ostream>

Namespaces

namespace  xronos::sdk
 Main Xronos SDK namespace.
namespace  xronos::sdk::operators
 Contains convenience streaming operators that allow printing time points and durations including their units.

Typedefs

using xronos::sdk::Duration = std::chrono::nanoseconds
 Data type used to represent durations.
using xronos::sdk::TimePoint = std::chrono::time_point<std::chrono::system_clock, std::chrono::nanoseconds>
 Data type used to represent time points.

Functions

auto xronos::sdk::operators::operator<< (std::ostream &os, TimePoint tp) -> std::ostream &
 Write a timepoint to an ostream.
auto xronos::sdk::operators::operator<< (std::ostream &os, std::chrono::seconds dur) -> std::ostream &
 Write a duration in seconds including the unit to an ostream.
auto xronos::sdk::operators::operator<< (std::ostream &os, std::chrono::milliseconds dur) -> std::ostream &
 Write a duration in milliseconds including the unit to an ostream.
auto xronos::sdk::operators::operator<< (std::ostream &os, std::chrono::microseconds dur) -> std::ostream &
 Write a duration in microseconds including the unit to an ostream.
auto xronos::sdk::operators::operator<< (std::ostream &os, std::chrono::nanoseconds dur) -> std::ostream &
 Write a duration in nanoseconds including the unit to an ostream.