|
lsst.astshim gf5dcc679e7+7aca86229d
|
A TimeFrame is a specialised form of one-dimensional Frame which represents various coordinate systems used to describe positions in time. More...
#include <TimeFrame.h>
Public Member Functions | |
| TimeFrame (std::string const &options="") | |
| Construct a TimeFrame. | |
| virtual | ~TimeFrame () |
| TimeFrame (TimeFrame const &)=default | |
| Copy constructor: make a deep copy. | |
| TimeFrame (TimeFrame &&)=default | |
| TimeFrame & | operator= (TimeFrame const &)=delete |
| TimeFrame & | operator= (TimeFrame &&)=default |
| std::shared_ptr< TimeFrame > | copy () const |
| Return a deep copy of this object. | |
| double | currentTime () const |
| Get the current system time. | |
| std::string | getAlignTimeScale () const |
| Get AlignTimeScale: time scale in which to align TimeFrames. | |
| double | getLTOffset () const |
| Get LTOffset: the offset of Local Time from UTC, in hours. | |
| double | getTimeOrigin () const |
| Get TimeOrigin: the zero point for TimeFrame axis values. | |
| std::string | getTimeScale () const |
| Get TimeScale: the timescale used by the TimeFrame. | |
| void | setAlignTimeScale (std::string const &scale) |
| Set AlignTimeScale: time scale in which to align TimeFrames. | |
| void | setLTOffset (double offset) |
| Set LTOffset: the offset of Local Time from UTC, in hours. | |
| void | setTimeOrigin (double origin) |
| Set TimeOrigin: the zero point for TimeFrame axis values. | |
| void | setTimeScale (std::string const &scale) |
| Set TimeScale: the timescale used by the TimeFrame. | |
Protected Member Functions | |
| virtual std::shared_ptr< Object > | copyPolymorphic () const override |
| TimeFrame (AstTimeFrame *rawptr) | |
| Construct a TimeFrame from a raw AST pointer. | |
Friends | |
| class | Object |
A TimeFrame is a specialised form of one-dimensional Frame which represents various coordinate systems used to describe positions in time.
A TimeFrame represents a moment in time as either an Modified Julian Date (MJD), a Julian Date (JD), a Besselian epoch or a Julian epoch, as determined by the System attribute. Optionally, a zero point can be specified (using attribute TimeOrigin) which results in the TimeFrame representing time offsets from the specified zero point.
Even though JD and MJD are defined as being in units of days, the TimeFrame class allows other units to be used (via the Unit attribute) on the basis of simple scalings (60 seconds = 1 minute, 60 minutes = 1 hour, 24 hours = 1 day, 365.25 days = 1 year). Likewise, Julian epochs can be described in units other than the usual years. Besselian epoch are always represented in units of (tropical) years.
The TimeScale attribute allows the time scale to be specified (that is, the physical process used to define the rate of flow of time). MJD, JD and Julian epoch can be used to represent a time in any supported time scale. However, Besselian epoch may only be used with the "TT" (Terrestrial Time) time scale. The list of supported time scales includes universal time and siderial time. Strictly, these represent angles rather than time scales, but are included in the list since they are in common use and are often thought of as time scales. When a time value is formatted it can be formated either as a simple floating point value, or as a Gregorian date (see the Format attribute).
TimeFrame has the following attributes in addition to those provided by Frame, Mapping and Object
Several of the Frame attributes inherited by the TimeFrame class refer to a specific axis of the Frame (for instance Unit(axis), Label(axis), etc). Since a TimeFrame is strictly one-dimensional, it allows these attributes to be specified without an axis index. So for instance, "Unit" is allowed in place of "Unit(1)".
Definition at line 80 of file TimeFrame.h.
|
inlineexplicit |
Construct a TimeFrame.
| [in] | options | Comma-separated list of attribute assignments. |
Definition at line 89 of file TimeFrame.h.
|
inlinevirtual |
Definition at line 94 of file TimeFrame.h.
|
default |
Copy constructor: make a deep copy.
|
default |
|
inlineexplicitprotected |
Construct a TimeFrame from a raw AST pointer.
Definition at line 159 of file TimeFrame.h.
|
inline |
Return a deep copy of this object.
Definition at line 103 of file TimeFrame.h.
|
inlineoverrideprotectedvirtual |
Definition at line 154 of file TimeFrame.h.
|
inline |
Get the current system time.
| std::runtime_error | if the frame has a TimeScale value which cannot be converted to TAI (e.g. " angular" systems such as UT1, GMST, LMST and LAST). |
Definition at line 123 of file TimeFrame.h.
|
inline |
Get AlignTimeScale: time scale in which to align TimeFrames.
Definition at line 130 of file TimeFrame.h.
|
inline |
Get LTOffset: the offset of Local Time from UTC, in hours.
Definition at line 133 of file TimeFrame.h.
|
inline |
Get TimeOrigin: the zero point for TimeFrame axis values.
Definition at line 136 of file TimeFrame.h.
|
inline |
Get TimeScale: the timescale used by the TimeFrame.
Definition at line 139 of file TimeFrame.h.
|
inline |
Set AlignTimeScale: time scale in which to align TimeFrames.
Definition at line 142 of file TimeFrame.h.
|
inline |
Set LTOffset: the offset of Local Time from UTC, in hours.
Definition at line 145 of file TimeFrame.h.
|
inline |
Set TimeOrigin: the zero point for TimeFrame axis values.
Definition at line 148 of file TimeFrame.h.
|
inline |
Set TimeScale: the timescale used by the TimeFrame.
Definition at line 151 of file TimeFrame.h.
|
friend |
Definition at line 81 of file TimeFrame.h.