![]() |
Lumiera 0.pre.04~rc.1
»edit your freedom«
|
#include "lib/time/timevalue.hpp"
basic constant internal time value.
These time values provide the implementation base for all further time types. They can be created by wrapping up a raw micro tick value (raw_time_64), are totally ordered, but besides that, they are opaque and non-mutable.
Definition at line 142 of file timevalue.hpp.
Static Public Attributes | |
| static const raw_time_64 | SCALE = 1'000'000 |
| Number of micro ticks (µs) per second as basic time scale. | |
Static Public Member Functions | |
| static TimeValue | buildRaw_ (raw_time_64) |
Public Member Functions | |
| TimeValue (raw_time_64 val) | |
| TimeValue (TimeValue const &o) | |
| copy initialisation allowed | |
| operator std::string () const | |
| bool | isRegular () const |
| std::strong_ordering | operator<=> (TimeValue const &) const =default |
| bool | operator== (TimeValue const &) const =default |
| std::strong_ordering | operator<=> (raw_time_64 tt) const |
| bool | operator== (raw_time_64 tt) const |
Friends | |
| class | Mutation |
| some subclasses may receive modification messages | |
| raw_time_64 | _raw (TimeValue const &time) |
| HashVal | hash_value (TimeValue const &) |
| derive a hash from the µ-tick value | |
Protected Member Functions | |
| TimeValue & | operator= (TimeValue const &o) |
| Assigning of time values is not allowed, but derived classed might allow that. | |
| TimeValue (TimeValue const &origin, TimeValue const &target) | |
Static Protected Member Functions | |
| static raw_time_64 | limitedTime (raw_time_64 raw) |
| explicit limit of allowed time range | |
| static raw_time_64 | limitedDelta (raw_time_64 origin, raw_time_64 target) |
| safe calculation of explicitly limited time offset | |
Protected Attributes | |
| raw_time_64 | t_ |
| the raw (internal) time value used to implement the time types | |
for Offset and Duration entities built on top
Definition at line 168 of file timevalue.hpp.
|
inlineexplicit |
| val | time given in µ ticks here |
Definition at line 178 of file timevalue.hpp.
copy initialisation allowed
Definition at line 183 of file timevalue.hpp.
Assigning of time values is not allowed, but derived classed might allow that.
Definition at line 153 of file timevalue.hpp.
References TimeValue::t_.
Referenced by Offset::operator=().
Here is the caller graph for this function:
|
inlinestaticprotected |
explicit limit of allowed time range
applies a limiter on the provided raw time value to keep it within the arbitrary boundaries defined by (Time::MAX, Time::MIN). While Time entities are not a "safeInt" implementation, we limit new values to lower the likelihood of wrap-around
Definition at line 760 of file timevalue.hpp.
References Time::MAX.
|
inlinestaticprotected |
safe calculation of explicitly limited time offset
Definition at line 766 of file timevalue.hpp.
References Duration::MAX.
|
static |
backdoor to sneak in a raw time value bypassing any normalisation and limiting
Definition at line 268 of file time.cpp.
Referenced by RealClock::_readSystemTime(), Offset::stretchedByFloatFactor(), and Offset::stretchedByRationalFactor().
Here is the caller graph for this function:
|
explicit |
diagnostics
|
inline |
Definition at line 787 of file timevalue.hpp.
References Time::MAX, and Time::MIN.
Referenced by LoadController::markLagSample(), ActivationEvent::refineTo(), LoadController::tendedNext(), and ActivityDetector::wasInvoked().
Here is the caller graph for this function:
|
default |
|
default |
|
inline |
Definition at line 202 of file timevalue.hpp.
|
inline |
Definition at line 203 of file timevalue.hpp.
References TimeValue::t_.
|
protected |
the raw (internal) time value used to implement the time types
Definition at line 147 of file timevalue.hpp.
Referenced by Duration::Duration(), TimeVar::operator FSecs(), TimeVar::operator*=(), TimeVar::operator+=(), TimeVar::operator-=(), TimeSpan::operator<=>(), TimeValue::operator=(), TimeValue::operator==(), Offset::stretchedByFloatFactor(), and Offset::stretchedByRationalFactor().
|
static |
Number of micro ticks (µs) per second as basic time scale.
Definition at line 174 of file timevalue.hpp.
Referenced by lib::time::__framerate_approximation(), stage::model::anonymous_namespace{zoom-window.hpp}::_FSecs(), ZoomWindow::addSafe(), lib::time::anonymous_namespace{time.cpp}::build_time_from(), lib::time::anonymous_namespace{quantiser.cpp}::calculate_quantisation(), TimeBasics_test::checkComponentBreakdown(), TimeValue_test::checkTimeConvenience(), QuantiserBasics_test::coverQuantisationCornerCases(), lib::time::anonymous_namespace{time.cpp}::framecount_to_time(), stage::widget::anonymous_namespace{timecode-widget.cpp}::getHours(), stage::widget::anonymous_namespace{timecode-widget.cpp}::getMins(), stage::widget::anonymous_namespace{timecode-widget.cpp}::getSecs(), Strategy< CONF >::initialEpochStep(), stage::model::anonymous_namespace{zoom-window.hpp}::isMicroGridAligned(), TimeVar::operator FSecs(), TimeControl_test::random_or_get(), TimeMutation_test::random_or_get(), ZoomWindow_test::safeguard_extremeTimePos(), ZoomWindow_test::safeguard_extremeZoomOut(), ZoomWindow_test::safeguard_poisonousMetric(), ZoomWindow_test::safeguard_toxic_zoomFactor(), ZoomWindow_test::safeguard_verySmall(), ZoomWindow::scaleSafe(), BlockFlow_test::storageFlow(), steam::test_format::test_createRawType(), ZoomWindow_test::verify_metric(), and ActivityDetector_test::verifyMockJobFunctor().
|
friend |
some subclasses may receive modification messages
Definition at line 160 of file timevalue.hpp.
|
friend |
to pass Time values to C functions
Definition at line 188 of file timevalue.hpp.
Referenced by TimeSpan::conform().
derive a hash from the µ-tick value
hash-standard.h Definition at line 741 of file timevalue.hpp.
Inheritance diagram for TimeValue:
Collaboration diagram for TimeValue: