A class to represent time period with time zone.
More...
#include <TimePeriodTZ.h>
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.
- See also
- DateTime, Date, DatePeriod, DateDuration, TimeInstant, TimeInstantTZ, TimePeriod, TimeDuration
Definition at line 54 of file TimePeriodTZ.h.
Constructor.
- Parameters
-
initialTime | A initial time instant. |
finalTime | A final time instant. |
te::dt::TimePeriodTZ::TimePeriodTZ |
( |
const boost::local_time::local_time_period & |
t | ) |
|
Constructor.
- Parameters
-
t | A time period with time zone. |
virtual te::dt::TimePeriodTZ::~TimePeriodTZ |
( |
| ) |
|
|
virtual |
DateTimeType te::dt::TimePeriodTZ::getDateTimeType |
( |
| ) |
const |
|
inlinevirtual |
It gets the final date time instant.
- Returns
- The final time instant
- Note
- The caller will take the ownership of the returned pointer.
Implements te::dt::DateTimePeriod.
TimeInstantTZ te::dt::TimePeriodTZ::getFinalTimeInstant |
( |
| ) |
const |
It gets the final time instant.
- Returns
- The final time instant
It gets the initial date time instant.
- Returns
- The initial time instant
- Note
- The caller will take the ownership of the returned pointer.
Implements te::dt::DateTimePeriod.
TimeInstantTZ te::dt::TimePeriodTZ::getInitialTimeInstant |
( |
| ) |
const |
It gets the initial time instant.
- Returns
- The initial time instant
const boost::local_time::local_time_period& te::dt::TimePeriodTZ::getTimePeriodTZ |
( |
| ) |
const |
|
inline |
It returns the boost time period with time zone type.
- Returns
- The boost time period with time zone type.
Definition at line 78 of file TimePeriodTZ.h.
boost::local_time::local_time_period& te::dt::TimePeriodTZ::getTimePeriodTZ |
( |
| ) |
|
|
inline |
It returns the boost time period with time zone type.
- Returns
- The boost time period with time zone type.
Definition at line 85 of file TimePeriodTZ.h.
int te::dt::DateTime::getTypeCode |
( |
| ) |
const |
|
inlinevirtualinherited |
It returns the data type code associated to date and time values: DATETIME_TYPE.
- Returns
- The data type code associated to the date and time values: DATETIME_TYPE.
Implements te::dt::AbstractData.
Definition at line 103 of file DateTime.h.
References te::dt::DATETIME_TYPE.
bool te::dt::TimePeriodTZ::operator!= |
( |
const DateTime & |
rhs | ) |
const |
|
virtual |
Operator !=.
- Parameters
-
rhs | The time period to be compared. |
- Returns
- It returns true if the two time periods are not equal. Otherwise, it returns false.
Implements te::dt::DateTime.
bool te::dt::TimePeriodTZ::operator< |
( |
const DateTime & |
rhs | ) |
const |
|
virtual |
Operator <.
- Parameters
-
rhs | The right-hand-side time period to be compared. |
- Returns
- It returns true if the right-hand-side time period is greater than the lefth side one. Otherwise, it returns false.
Implements te::dt::DateTime.
bool te::dt::TimePeriodTZ::operator== |
( |
const DateTime & |
rhs | ) |
const |
|
virtual |
Operator ==.
- Parameters
-
rhs | The time period to be compared. |
- Returns
- It returns true if the two time period are equal. Otherwise, it returns false.
Implements te::dt::DateTime.
bool te::dt::TimePeriodTZ::operator> |
( |
const DateTime & |
rhs | ) |
const |
|
virtual |
Operator >
- Parameters
-
rhs | The right-hand-side time period to be compared. |
- Returns
- It returns true if the right-hand-side time period is less than the lefth side one. Otherwise, it returns false.
Implements te::dt::DateTime.
std::string te::dt::TimePeriodTZ::toString |
( |
| ) |
const |
|
virtual |
It returns the time period with time zone in the ISO textual format (YYYYMMDDThhmmss±hhmm/YYYYMMDDThhmmss±hhmm).
- Returns
- The time period with time zone in the ISO textual format (YYYYMMDDThhmmss±hhmm/YYYYMMDDThhmmss±hhmm).
Implements te::dt::AbstractData.
boost::local_time::local_time_period te::dt::TimePeriodTZ::m_timePeriodTZ |
|
protected |
Time period with time zone information.
Definition at line 183 of file TimePeriodTZ.h.
The documentation for this class was generated from the following file:
- /home/castejon/castejon_files/develop/terralib5/git_master/terralib5/src/terralib/datatype/TimePeriodTZ.h