|
tempoch-cpp 0.5.3
Header-only C++ wrapper for tempoch
|
Namespaces | |
| namespace | constants |
| namespace | detail |
| namespace | format |
| namespace | scale |
Typedefs | |
| using | TTMjdPeriod = Period< ModifiedJulianDate< scale::TT > > |
| using | UTCPeriod = Period< CivilTime > |
| template<typename S > | |
| using | JulianDate = EncodedTime< S, format::JD > |
| template<typename S > | |
| using | ModifiedJulianDate = EncodedTime< S, format::MJD > |
| template<typename S > | |
| using | J2000Seconds = EncodedTime< S, format::J2000s > |
| using | UnixTime = EncodedTime< scale::UTC, format::Unix > |
| using | GpsTime = EncodedTime< scale::TAI, format::GPS > |
Enumerations | |
| enum class | TimeDataSource : int { Bundled = 0 , RuntimeCache = 1 , Override = 2 } |
Functions | |
| std::ostream & | operator<< (std::ostream &os, const CivilTime &u) |
| Stream CivilTime as YYYY-MM-DD HH:MM:SS[.nnnnnnnnn]. | |
| double | delta_t_seconds (double jd_ut1) noexcept |
| double | delta_t_seconds_extrapolated (double jd_ut1) noexcept |
| TimeDataStatus | time_data_status () |
| bool | eop_covers (double mjd_utc) noexcept |
Check whether EOP data is available for mjd_utc. | |
| std::optional< EopValues > | eop_at (double mjd_utc) |
Interpolate IERS EOP values at mjd_utc. | |
| void | check_status (tempoch_status_t status, const char *operation) |
| Check a tempoch_status_t and throw the appropriate exception on error. | |
| template<typename S , std::enable_if_t< is_gnss_scale_v< S >, int > = 0> | |
| GnssWeek | to_gnss_week (const Time< S > &time) |
| Decompose a GNSS-scale instant into its week-number form. | |
| template<typename S , std::enable_if_t< is_gnss_scale_v< S >, int > = 0> | |
| Time< S > | from_gnss_week (const GnssWeek &gw) |
| Build a GNSS-scale instant from a week-number decomposition. | |
| template<typename T > | |
| Period (T, T) -> Period< T > | |
| template<typename T > | |
| void | validate_periods (const std::vector< Period< T > > &periods) |
| template<typename T > | |
| std::vector< Period< T > > | intersect_periods (const std::vector< Period< T > > &a, const std::vector< Period< T > > &b) |
| template<typename T > | |
| std::vector< Period< T > > | union_periods (const std::vector< Period< T > > &a, const std::vector< Period< T > > &b) |
| template<typename T > | |
| std::vector< Period< T > > | normalize_periods (const std::vector< Period< T > > &periods) |
| template<typename T > | |
| std::ostream & | operator<< (std::ostream &os, const Period< T > &period) |
| template<typename S > | |
| std::ostream & | operator<< (std::ostream &os, const Time< S > &time) |
| template<typename S , typename F > | |
| std::ostream & | operator<< (std::ostream &os, const EncodedTime< S, F > &time) |
Variables | |
| template<typename T > | |
| constexpr bool | is_format_v = is_format<T>::value |
| template<typename F > | |
| constexpr tempoch_format_tag_t | format_tag_v = FormatTraits<F>::ffi_tag |
| template<typename S > | |
| constexpr bool | is_gnss_scale_v = is_gnss_scale<S>::value |
| template<typename T > | |
| constexpr bool | is_scale_v = is_scale<T>::value |
| template<typename S > | |
| constexpr tempoch_scale_tag_t | scale_tag_v = ScaleTraits<S>::ffi_tag |
Definition at line 131 of file period.hpp.
Definition at line 132 of file period.hpp.
|
strong |
Origin of the currently active time-data bundle.
Mirrors tempoch::ActiveTimeDataSource.
| Enumerator | |
|---|---|
| Bundled | Compiled archive snapshot bundled at build time. |
| RuntimeCache | Bundle loaded through the runtime fetch/cache path. |
| Override | Test or caller-provided override is active. |
Definition at line 23 of file data_status.hpp.
|
inline |
Check a tempoch_status_t and throw the appropriate exception on error.
Definition at line 139 of file ffi_core.hpp.
Referenced by tempoch::detail::add_seconds(), tempoch::Period< T >::complement_of(), tempoch::detail::decode_time(), tempoch::detail::difference_seconds(), tempoch::detail::encode_time(), eop_at(), from_gnss_week(), intersect_periods(), tempoch::Period< T >::intersection(), tempoch::detail::make_builtin_eop_context(), tempoch::detail::make_default_context(), tempoch::detail::make_pre_definition_context(), tempoch::detail::make_time(), normalize_periods(), tempoch::Period< T >::Period(), tempoch::detail::scale_convert(), time_data_status(), tempoch::detail::time_from_civil(), tempoch::detail::time_to_civil(), to_gnss_week(), union_periods(), tempoch::Period< T >::union_with(), and validate_periods().
ΔT = TT − UT1 in seconds for a UT1 Julian Day, using the compiled USNO model. Returns NaN when the requested epoch is outside the model domain.
Definition at line 87 of file constants.hpp.
ΔT = TT − UT1 in seconds for a UT1 Julian Day, extrapolating beyond the tabulated range with the long-term parabola (always finite).
Definition at line 91 of file constants.hpp.
Interpolate IERS EOP values at mjd_utc.
| mjd_utc | UTC Modified Julian Date of the desired epoch. |
std::optional<EopValues> containing the result, or std::nullopt when the epoch is outside the compiled data range.Definition at line 81 of file eop.hpp.
References check_status(), and tempoch::EopValues::mjd_utc.
Build a GNSS-scale instant from a week-number decomposition.
Definition at line 56 of file gnss_week.hpp.
References check_status(), tempoch::Time< S >::from_split_seconds(), and scale_tag_v.
|
inline |
Definition at line 163 of file period.hpp.
References check_status(), scale_tag_v, and tempoch::detail::to_raw().
|
inline |
Definition at line 185 of file period.hpp.
References check_status(), scale_tag_v, and tempoch::detail::to_raw().
|
inline |
Stream CivilTime as YYYY-MM-DD HH:MM:SS[.nnnnnnnnn].
Definition at line 57 of file civil_time.hpp.
References tempoch::CivilTime::day, tempoch::CivilTime::hour, tempoch::CivilTime::minute, tempoch::CivilTime::month, tempoch::CivilTime::nanosecond, tempoch::CivilTime::second, and tempoch::CivilTime::year.
|
inline |
Definition at line 506 of file time_base.hpp.
References scale_tag_v.
|
inline |
Definition at line 194 of file period.hpp.
References scale_tag_v.
|
inline |
Definition at line 305 of file time_base.hpp.
References scale_tag_v.
| tempoch::Period | ( | T | , |
| T | |||
| ) | -> Period< T > |
|
inline |
Capture the status of the currently active time-data bundle.
Mirrors tempoch::time_data_status().
Definition at line 63 of file data_status.hpp.
References check_status(), tempoch::DataHorizons::delta_t_prediction_horizon_mjd, tempoch::DataHorizons::eop_end_mjd, tempoch::DataHorizons::eop_observed_end_mjd, tempoch::DataHorizons::eop_start_mjd, tempoch::TimeDataStatus::horizons, tempoch::DataHorizons::modern_delta_t_observed_end_mjd, and tempoch::TimeDataStatus::source.
Decompose a GNSS-scale instant into its week-number form.
Definition at line 46 of file gnss_week.hpp.
References tempoch::Time< S >::c_inner(), check_status(), scale_tag_v, and tempoch::GnssWeek::week.
|
inline |
Definition at line 174 of file period.hpp.
References check_status(), scale_tag_v, and tempoch::detail::to_raw().
|
inline |
Definition at line 157 of file period.hpp.
References check_status(), scale_tag_v, and tempoch::detail::to_raw().
|
inlineconstexpr |
Definition at line 13 of file formats/base.hpp.
Definition at line 10 of file formats/base.hpp.
|
inlineconstexpr |
Definition at line 28 of file gnss_week.hpp.
Definition at line 9 of file scales/base.hpp.
|
inlineconstexpr |
Definition at line 12 of file scales/base.hpp.
Referenced by tempoch::detail::add_seconds(), tempoch::Period< T >::complement_of(), tempoch::Period< T >::contains(), tempoch::detail::decode_time(), tempoch::detail::difference_seconds(), tempoch::Period< T >::duration(), tempoch::detail::encode_time(), tempoch::detail::ensure_finite_encoded(), tempoch::detail::from_alloc(), tempoch::Period< T >::from_c(), tempoch::Time< S >::from_civil(), tempoch::Time< S >::from_civil(), tempoch::Time< S >::from_encoded(), tempoch::Time< S >::from_encoded_with(), from_gnss_week(), tempoch::EncodedTime< S, F >::from_jd(), tempoch::EncodedTime< S, F >::from_mjd(), tempoch::TimeTraits< Time< S > >::from_mjd_value(), tempoch::TimeTraits< EncodedTime< S, F > >::from_mjd_value(), tempoch::TimeTraits< CivilTime >::from_mjd_value(), tempoch::Time< S >::from_raw_j2000_seconds(), tempoch::Time< S >::from_split_seconds(), tempoch::EncodedTime< S, F >::from_utc(), tempoch::EncodedTime< S, F >::from_utc(), intersect_periods(), tempoch::Period< T >::intersection(), tempoch::EncodedTime< S, F >::J2000(), tempoch::Period< T >::length(), tempoch::detail::make_builtin_eop_context(), tempoch::detail::make_default_context(), tempoch::detail::make_pre_definition_context(), tempoch::detail::make_time(), tempoch::EncodedTime< S, F >::max(), tempoch::EncodedTime< S, F >::mean(), tempoch::EncodedTime< S, F >::min(), normalize_periods(), tempoch::EncodedTime< S, F >::operator!=(), tempoch::Time< S >::operator!=(), tempoch::detail::ContextDeleter::operator()(), tempoch::Time< S >::operator+(), tempoch::EncodedTime< S, F >::operator+(), tempoch::Time< S >::operator+=(), tempoch::EncodedTime< S, F >::operator+=(), tempoch::EncodedTime< S, F >::operator-(), tempoch::Time< S >::operator-(), tempoch::EncodedTime< S, F >::operator-(), tempoch::Time< S >::operator-(), tempoch::Time< S >::operator-=(), tempoch::EncodedTime< S, F >::operator-=(), tempoch::EncodedTime< S, F >::operator<(), tempoch::Time< S >::operator<(), operator<<(), operator<<(), operator<<(), tempoch::EncodedTime< S, F >::operator<=(), tempoch::Time< S >::operator<=(), tempoch::EncodedTime< S, F >::operator==(), tempoch::Time< S >::operator==(), tempoch::EncodedTime< S, F >::operator>(), tempoch::Time< S >::operator>(), tempoch::EncodedTime< S, F >::operator>=(), tempoch::Time< S >::operator>=(), tempoch::Period< T >::Period(), tempoch::detail::scale_convert(), tempoch::detail::time_from_civil(), tempoch::detail::time_to_civil(), tempoch::Time< S >::to(), tempoch::EncodedTime< S, F >::to(), tempoch::Time< S >::to_civil(), to_gnss_week(), tempoch::EncodedTime< S, F >::to_jd(), tempoch::EncodedTime< S, F >::to_mjd(), tempoch::TimeTraits< CivilTime >::to_mjd_value(), tempoch::TimeTraits< EncodedTime< S, F > >::to_mjd_value(), tempoch::TimeTraits< Time< S > >::to_mjd_value(), tempoch::detail::to_raw(), tempoch::EncodedTime< S, F >::to_utc(), tempoch::EncodedTime< S, F >::to_utc(), tempoch::Time< S >::to_with(), tempoch::EncodedTime< S, F >::to_with(), tempoch::Time< S >::try_to(), tempoch::EncodedTime< S, F >::try_to(), union_periods(), tempoch::Period< T >::union_with(), and validate_periods().