BloombergLP::bsls::TimeInterval::isValid

isValid overloads

Synopses

Declared in <bsls_timeinterval.h>

Return true if a TimeInterval object can be constructed from the specified duration, and false otherwise. A time interval can be constructed from duration if duration's value converted to seconds can be represented with a 64-bit signed integer.

template<
    class REP,
    class PERIOD>
static
bool
isValid(std::chrono::duration<REP, PERIOD> const& duration);
» more...

Return true if a TimeInterval object can be constructed from the specified seconds and nanoseconds, and false otherwise. A time interval can be constructed from seconds and nanoseconds if their sum results in a time interval whose total number of seconds can be represented with a 64-bit signed integer.

constexpr
static
bool
isValid(
    bsls::Types::Int64 seconds,
    int nanoseconds);
» more...