ocssw
V2022
|
#include <LeapSecondDatabase.hpp>
Public Member Functions | |
LeapSecondDatabase () | |
LeapSecondDatabase (const std::string &file) | |
float | leap_seconds_since (const boost::posix_time::ptime &time) |
bool | is_leap_second (const boost::posix_time::ptime &time) |
Static Public Member Functions | |
static LeapSecondDatabase & | get_default () |
Detailed Description
Constructor & Destructor Documentation
◆ LeapSecondDatabase() [1/2]
Default constructor, using default locations for database file.
The default locations are checked are:
- The environment variable $LEAPSECOND_DAT
- $OCVARROOT/viirsn/IETTime.dat
- $OCVARROOT/modis/leapsec.dat
◆ LeapSecondDatabase() [2/2]
|
inlineexplicit |
Read the database at the given location.
Definition at line 57 of file LeapSecondDatabase.hpp.
Member Function Documentation
◆ get_default()
|
inlinestatic |
Obtain a singleton of a default database.
Definition at line 61 of file LeapSecondDatabase.hpp.
◆ is_leap_second()
Check if a given time is a leap second.
- Parameters
-
time The date/time to check
- Returns
- true if time is a leap second
◆ leap_seconds_since()
float leap_seconds_since | ( | const boost::posix_time::ptime & | time | ) |
Look up how many leap seconds are in effect on a given date.
- Parameters
-
time The date/time to check
- Returns
- the number of leap seconds in effect
The documentation for this class was generated from the following file:
- /gfs-oceanweb/web/ocssw/ocssw_src/include/focs/LeapSecondDatabase.hpp