Time Shield Library
C++ library for working with time
|
A collection of constants for time calculations and conversions. More...
Variables | |
constexpr int64_t | time_shield::NS_PER_US = 1000 |
Nanoseconds per microsecond. | |
constexpr int64_t | time_shield::NS_PER_MS = 1000000 |
Nanoseconds per millisecond. | |
constexpr int64_t | time_shield::NS_PER_SEC = 1000000000 |
Nanoseconds per second. | |
constexpr int64_t | time_shield::US_PER_SEC = 1000000 |
Microseconds per second. | |
constexpr int64_t | time_shield::MS_PER_SEC = 1000 |
Milliseconds per second. | |
constexpr int64_t | time_shield::MS_PER_5_SEC = 5000 |
Milliseconds per 5 second. | |
constexpr int64_t | time_shield::MS_PER_10_SEC = 5000 |
Milliseconds per 10 second. | |
constexpr int64_t | time_shield::MS_PER_15_SEC = 15000 |
Milliseconds per 15 second. | |
constexpr int64_t | time_shield::MS_PER_30_SEC = 30000 |
Milliseconds per 30 second. | |
constexpr int64_t | time_shield::MS_PER_MIN = 60000 |
Milliseconds per minute. | |
constexpr int64_t | time_shield::MS_PER_5_MIN = 300000 |
Milliseconds per 5 minute. | |
constexpr int64_t | time_shield::MS_PER_10_MIN = 600000 |
Milliseconds per 10 minute. | |
constexpr int64_t | time_shield::MS_PER_15_MIN = 900000 |
Milliseconds per 15 minute. | |
constexpr int64_t | time_shield::MS_PER_30_MIN = 1800000 |
Milliseconds per 30 minute. | |
constexpr int64_t | time_shield::MS_PER_HALF_HOUR = 1800000 |
Milliseconds per half hour. | |
constexpr int64_t | time_shield::MS_PER_HOUR = 3600000 |
Milliseconds per hour. | |
constexpr int64_t | time_shield::MS_PER_DAY = 86400000 |
Milliseconds per day. | |
constexpr int64_t | time_shield::SEC_PER_MIN = 60 |
Seconds per minute. | |
constexpr int64_t | time_shield::SEC_PER_3_MIN = 180 |
Seconds per 3 minute. | |
constexpr int64_t | time_shield::SEC_PER_5_MIN = 300 |
Seconds per 5 minute. | |
constexpr int64_t | time_shield::SEC_PER_10_MIN = 600 |
Seconds per 10 minute. | |
constexpr int64_t | time_shield::SEC_PER_15_MIN = 900 |
Seconds per 15 minute. | |
constexpr int64_t | time_shield::SEC_PER_HALF_HOUR = 1800 |
Seconds per half hour. | |
constexpr int64_t | time_shield::SEC_PER_HOUR = 3600 |
Seconds per hour. | |
constexpr int64_t | time_shield::SEC_PER_DAY = 86400 |
Seconds per day. | |
constexpr int64_t | time_shield::SEC_PER_YEAR = 31536000 |
Seconds per year (365 days) | |
constexpr int64_t | time_shield::AVG_SEC_PER_YEAR = 31557600 |
Average seconds per year (365.25 days) | |
constexpr int64_t | time_shield::SEC_PER_LEAP_YEAR = 31622400 |
Seconds per leap year (366 days) | |
constexpr int64_t | time_shield::SEC_PER_4_YEARS = 126230400 |
Seconds per 4 years. | |
constexpr int64_t | time_shield::SEC_PER_FIRST_100_YEARS = 3155760000 |
Seconds per first 100 years. | |
constexpr int64_t | time_shield::SEC_PER_100_YEARS = 3155673600 |
Seconds per 100 years. | |
constexpr int64_t | time_shield::SEC_PER_400_YEARS = 12622780800 |
Seconds per 400 years. | |
constexpr int64_t | time_shield::MAX_SEC_PER_DAY = 86399 |
Maximum seconds per day. | |
constexpr int64_t | time_shield::MIN_PER_HOUR = 60 |
Minutes per hour. | |
constexpr int64_t | time_shield::MIN_PER_DAY = 1440 |
Minutes per day. | |
constexpr int64_t | time_shield::MIN_PER_2_DAY = 2*1440 |
Minutes per 2 day. | |
constexpr int64_t | time_shield::MIN_PER_5_DAY = 5*1440 |
Minutes per 5 day. | |
constexpr int64_t | time_shield::MIN_PER_7_DAY = 7*1440 |
Minutes per 7 day. | |
constexpr int64_t | time_shield::MIN_PER_WEEK = 10080 |
Minutes per week. | |
constexpr int64_t | time_shield::MIN_PER_10_DAY = 10*1440 |
Minutes per 10 day. | |
constexpr int64_t | time_shield::MIN_PER_15_DAY = 15*1440 |
Minutes per 15 day. | |
constexpr int64_t | time_shield::MIN_PER_30_DAY = 15*1440 |
Minutes per 30 day. | |
constexpr int64_t | time_shield::MIN_PER_MONTH = 40320 |
Minutes per month (28 days) | |
constexpr int64_t | time_shield::MAX_MOON_MIN = 42523 |
Maximum lunar minutes. | |
constexpr int64_t | time_shield::HOURS_PER_DAY = 24 |
Hours per day. | |
constexpr int64_t | time_shield::DAYS_PER_WEEK = 7 |
Days per week. | |
constexpr int64_t | time_shield::DAYS_PER_LEAP_YEAR = 366 |
Days per leap year. | |
constexpr int64_t | time_shield::DAYS_PER_YEAR = 365 |
Days per year. | |
constexpr int64_t | time_shield::DAYS_PER_4_YEARS = 1461 |
Days per 4 years. | |
const int64_t | time_shield::MONTHS_PER_YEAR = 12 |
Months per year. | |
const int64_t | time_shield::MAX_DAYS_PER_MONTH = 31 |
Maximum days per month. | |
const int64_t | time_shield::LEAP_YEAR_PER_100_YEAR = 24 |
Leap years per 100 years. | |
const int64_t | time_shield::LEAP_YEAR_PER_400_YEAR = 97 |
Leap years per 400 years. | |
constexpr int64_t | time_shield::UNIX_EPOCH = 1970 |
Start year of UNIX time. | |
constexpr int64_t | time_shield::OLE_EPOCH = 25569 |
OLE automation date since UNIX epoch. | |
constexpr int64_t | time_shield::MAX_YEAR = 292277022000LL |
Maximum representable year. | |
constexpr int64_t | time_shield::MIN_YEAR = -2967369602200LL |
Minimum representable year. | |
constexpr int64_t | time_shield::ERROR_YEAR = 9223372036854770000LL |
Error year value. | |
constexpr int64_t | time_shield::MAX_TIMESTAMP = 9223371890843040000LL |
Maximum timestamp value. | |
constexpr int64_t | time_shield::ERROR_TIMESTAMP = 9223372036854770000LL |
Error timestamp value. | |
constexpr double | time_shield::MAX_OADATE = std::numeric_limits<double>::max() |
Maximum OLE automation date. | |
constexpr double | time_shield::AVG_DAYS_PER_YEAR = 365.25 |
Average days per year. | |
A collection of constants for time calculations and conversions.
This group includes constants for time units (nanoseconds, microseconds, milliseconds, seconds, minutes, hours, days), and other values related to the representation of time, such as UNIX and OLE epochs.
|
constexpr |
Average days per year.
Definition at line 105 of file constants.hpp.
|
constexpr |
Average seconds per year (365.25 days)
Definition at line 62 of file constants.hpp.
|
constexpr |
Days per 4 years.
Definition at line 88 of file constants.hpp.
|
constexpr |
Days per leap year.
Definition at line 86 of file constants.hpp.
|
constexpr |
Days per week.
Definition at line 85 of file constants.hpp.
|
constexpr |
Days per year.
Definition at line 87 of file constants.hpp.
|
constexpr |
Error timestamp value.
Definition at line 103 of file constants.hpp.
|
constexpr |
Error year value.
Definition at line 101 of file constants.hpp.
|
constexpr |
Hours per day.
Definition at line 84 of file constants.hpp.
const int64_t time_shield::LEAP_YEAR_PER_100_YEAR = 24 |
Leap years per 100 years.
Definition at line 93 of file constants.hpp.
const int64_t time_shield::LEAP_YEAR_PER_400_YEAR = 97 |
Leap years per 400 years.
Definition at line 94 of file constants.hpp.
const int64_t time_shield::MAX_DAYS_PER_MONTH = 31 |
Maximum days per month.
Definition at line 92 of file constants.hpp.
|
constexpr |
Maximum lunar minutes.
Definition at line 81 of file constants.hpp.
|
constexpr |
Maximum OLE automation date.
Definition at line 104 of file constants.hpp.
|
constexpr |
Maximum seconds per day.
Definition at line 68 of file constants.hpp.
|
constexpr |
Maximum timestamp value.
Definition at line 102 of file constants.hpp.
|
constexpr |
Maximum representable year.
Definition at line 99 of file constants.hpp.
|
constexpr |
Minutes per 10 day.
Definition at line 77 of file constants.hpp.
|
constexpr |
Minutes per 15 day.
Definition at line 78 of file constants.hpp.
|
constexpr |
Minutes per 2 day.
Definition at line 73 of file constants.hpp.
|
constexpr |
Minutes per 30 day.
Definition at line 79 of file constants.hpp.
|
constexpr |
Minutes per 5 day.
Definition at line 74 of file constants.hpp.
|
constexpr |
Minutes per 7 day.
Definition at line 75 of file constants.hpp.
|
constexpr |
Minutes per day.
Definition at line 72 of file constants.hpp.
|
constexpr |
Minutes per hour.
Definition at line 71 of file constants.hpp.
|
constexpr |
Minutes per month (28 days)
Definition at line 80 of file constants.hpp.
|
constexpr |
Minutes per week.
Definition at line 76 of file constants.hpp.
|
constexpr |
Minimum representable year.
Definition at line 100 of file constants.hpp.
const int64_t time_shield::MONTHS_PER_YEAR = 12 |
Months per year.
Definition at line 91 of file constants.hpp.
|
constexpr |
Milliseconds per 10 minute.
Definition at line 45 of file constants.hpp.
|
constexpr |
Milliseconds per 10 second.
Definition at line 40 of file constants.hpp.
|
constexpr |
Milliseconds per 15 minute.
Definition at line 46 of file constants.hpp.
|
constexpr |
Milliseconds per 15 second.
Definition at line 41 of file constants.hpp.
|
constexpr |
Milliseconds per 30 minute.
Definition at line 47 of file constants.hpp.
|
constexpr |
Milliseconds per 30 second.
Definition at line 42 of file constants.hpp.
|
constexpr |
Milliseconds per 5 minute.
Definition at line 44 of file constants.hpp.
|
constexpr |
Milliseconds per 5 second.
Definition at line 39 of file constants.hpp.
|
constexpr |
Milliseconds per day.
Definition at line 50 of file constants.hpp.
|
constexpr |
Milliseconds per half hour.
Definition at line 48 of file constants.hpp.
|
constexpr |
Milliseconds per hour.
Definition at line 49 of file constants.hpp.
|
constexpr |
Milliseconds per minute.
Definition at line 43 of file constants.hpp.
|
constexpr |
Milliseconds per second.
Definition at line 38 of file constants.hpp.
|
constexpr |
Nanoseconds per millisecond.
Definition at line 33 of file constants.hpp.
|
constexpr |
Nanoseconds per second.
Definition at line 34 of file constants.hpp.
|
constexpr |
Nanoseconds per microsecond.
Definition at line 32 of file constants.hpp.
|
constexpr |
OLE automation date since UNIX epoch.
Definition at line 98 of file constants.hpp.
|
constexpr |
Seconds per 100 years.
Definition at line 66 of file constants.hpp.
|
constexpr |
Seconds per 10 minute.
Definition at line 56 of file constants.hpp.
|
constexpr |
Seconds per 15 minute.
Definition at line 57 of file constants.hpp.
|
constexpr |
Seconds per 3 minute.
Definition at line 54 of file constants.hpp.
|
constexpr |
Seconds per 400 years.
Definition at line 67 of file constants.hpp.
|
constexpr |
Seconds per 4 years.
Definition at line 64 of file constants.hpp.
|
constexpr |
Seconds per 5 minute.
Definition at line 55 of file constants.hpp.
|
constexpr |
Seconds per day.
Definition at line 60 of file constants.hpp.
|
constexpr |
Seconds per first 100 years.
Definition at line 65 of file constants.hpp.
|
constexpr |
Seconds per half hour.
Definition at line 58 of file constants.hpp.
|
constexpr |
Seconds per hour.
Definition at line 59 of file constants.hpp.
|
constexpr |
Seconds per leap year (366 days)
Definition at line 63 of file constants.hpp.
|
constexpr |
Seconds per minute.
Definition at line 53 of file constants.hpp.
|
constexpr |
Seconds per year (365 days)
Definition at line 61 of file constants.hpp.
|
constexpr |
Start year of UNIX time.
Definition at line 97 of file constants.hpp.
|
constexpr |
Microseconds per second.
Definition at line 37 of file constants.hpp.