A class to represent time period with time zone. More...
#include <TimePeriodTZ.h>
Public Member Functions | |
| AbstractData * | clone () const |
| It returns a clone of this object. More... | |
| DateTimeType | getDateTimeType () const |
| It returns the subtype of the date and time type. More... | |
| DateTimeInstant * | getFinalInstant () const |
| It gets the final date time instant. More... | |
| TimeInstantTZ | getFinalTimeInstant () const |
| It gets the final time instant. More... | |
| DateTimeInstant * | getInitialInstant () const |
| It gets the initial date time instant. More... | |
| TimeInstantTZ | getInitialTimeInstant () const |
| It gets the initial time instant. More... | |
| const boost::local_time::local_time_period & | getTimePeriodTZ () const |
| It returns the boost time period with time zone type. More... | |
| boost::local_time::local_time_period & | getTimePeriodTZ () |
| It returns the boost time period with time zone type. More... | |
| int | getTypeCode () const |
| It returns the data type code associated to date and time values: DATETIME_TYPE. More... | |
| bool | operator!= (const DateTime &rhs) const |
| Operator !=. More... | |
| bool | operator< (const DateTime &rhs) const |
| Operator <. More... | |
| bool | operator== (const DateTime &rhs) const |
| Operator ==. More... | |
| bool | operator> (const DateTime &rhs) const |
| Operator > More... | |
| TimePeriodTZ (const TimeInstantTZ &initialTime, const TimeInstantTZ &finalTime) | |
| Constructor. More... | |
| TimePeriodTZ (const boost::local_time::local_time_period &t) | |
| Constructor. More... | |
| std::string | toString () const |
| It returns the time period with time zone in the ISO textual format (YYYYMMDDThhmmss±hhmm/YYYYMMDDThhmmss±hhmm). More... | |
| virtual | ~TimePeriodTZ () |
| Destructor. More... | |
Protected Attributes | |
| boost::local_time::local_time_period | m_timePeriodTZ |
| Time period with time zone information. More... | |
A class to represent time period with time zone.
A time period is a part of the continous time axis limited by two time instants with time zone. Each time instant with time zone is composed of a date that uses the Gregorian calendar and of a time with an associated time zone. Internally, it uses the datetime boost library to represent time period with time zone, by using the data type boost::local_time::local_time_period.
Definition at line 54 of file TimePeriodTZ.h.
| te::dt::TimePeriodTZ::TimePeriodTZ | ( | const TimeInstantTZ & | initialTime, |
| const TimeInstantTZ & | finalTime | ||
| ) |
Constructor.
| initialTime | A initial time instant. |
| finalTime | A final time instant. |
Definition at line 30 of file TimePeriodTZ.cpp.
| te::dt::TimePeriodTZ::TimePeriodTZ | ( | const boost::local_time::local_time_period & | t | ) |
Constructor.
| t | A time period with time zone. |
Definition at line 35 of file TimePeriodTZ.cpp.
|
virtual |
Destructor.
Definition at line 104 of file TimePeriodTZ.cpp.
|
virtual |
It returns a clone of this object.
Implements te::dt::AbstractData.
Definition at line 84 of file TimePeriodTZ.cpp.
|
inlinevirtual |
It returns the subtype of the date and time type.
Implements te::dt::DateTime.
Definition at line 174 of file TimePeriodTZ.h.
References te::dt::TIME_PERIOD_TZ.
|
virtual |
It gets the final date time instant.
Implements te::dt::DateTimePeriod.
Definition at line 55 of file TimePeriodTZ.cpp.
| te::dt::TimeInstantTZ te::dt::TimePeriodTZ::getFinalTimeInstant | ( | ) | const |
It gets the final time instant.
Definition at line 45 of file TimePeriodTZ.cpp.
|
virtual |
It gets the initial date time instant.
Implements te::dt::DateTimePeriod.
Definition at line 50 of file TimePeriodTZ.cpp.
| te::dt::TimeInstantTZ te::dt::TimePeriodTZ::getInitialTimeInstant | ( | ) | const |
It gets the initial time instant.
Definition at line 40 of file TimePeriodTZ.cpp.
|
inline |
It returns the boost time period with time zone type.
Definition at line 78 of file TimePeriodTZ.h.
|
inline |
It returns the boost time period with time zone type.
Definition at line 85 of file TimePeriodTZ.h.
|
inlinevirtualinherited |
It returns the data type code associated to date and time values: DATETIME_TYPE.
Implements te::dt::AbstractData.
Definition at line 103 of file DateTime.h.
References te::dt::DATETIME_TYPE.
|
virtual |
Operator !=.
| rhs | The time period to be compared. |
Implements te::dt::DateTime.
Definition at line 66 of file TimePeriodTZ.cpp.
References m_timePeriodTZ.
|
virtual |
Operator <.
| rhs | The right-hand-side time period to be compared. |
Implements te::dt::DateTime.
Definition at line 72 of file TimePeriodTZ.cpp.
References m_timePeriodTZ.
|
virtual |
Operator ==.
| rhs | The time period to be compared. |
Implements te::dt::DateTime.
Definition at line 60 of file TimePeriodTZ.cpp.
References m_timePeriodTZ.
|
virtual |
Operator >
| rhs | The right-hand-side time period to be compared. |
Implements te::dt::DateTime.
Definition at line 78 of file TimePeriodTZ.cpp.
References m_timePeriodTZ.
|
virtual |
It returns the time period with time zone in the ISO textual format (YYYYMMDDThhmmss±hhmm/YYYYMMDDThhmmss±hhmm).
Implements te::dt::AbstractData.
Definition at line 89 of file TimePeriodTZ.cpp.
|
protected |
Time period with time zone information.
Definition at line 183 of file TimePeriodTZ.h.
Referenced by operator!=(), operator<(), operator==(), and operator>().