A class to represent date duration. More...
#include <DateDuration.h>
Public Member Functions | |
| AbstractData * | clone () const |
| It returns a clone of this object. | |
| DateDuration () | |
| Empty constructor. | |
| DateDuration (const boost::gregorian::date_duration &dd) | |
| Constructor. | |
| DateDuration (const te::dt::DateDuration &rhs) | |
| Copy Constructor. | |
| DateDuration (long dd) | |
| Constructor. | |
| boost::gregorian::date_duration & | getDateDuration () |
| It returns the boost date duration type. | |
| const boost::gregorian::date_duration & | getDateDuration () const |
| It returns the boost date duration type. | |
| DateTimeType | getDateTimeType () const |
| It returns the subtype of the date and time type. | |
| int | getTypeCode () const |
| It returns the data type code associated to date and time values: DATETIME_TYPE. | |
| bool | operator!= (const DateTime &rhs) const |
| Operator !=. | |
| bool | operator< (const DateTime &rhs) const |
| Operator <. | |
| DateDuration & | operator= (const DateDuration &date) |
| Operator =. | |
| bool | operator== (const DateTime &rhs) const |
| Operator ==. | |
| bool | operator> (const DateTime &rhs) const |
| Operator > | |
| std::string | toString () const |
| It returns the date duration in a textual format. | |
| virtual | ~DateDuration () |
| Destructor. | |
Protected Attributes | |
| std::unique_ptr< DateDurationImpl > | m_dateDurationImpl |
| Date duration information. | |
A class to represent date duration.
A date duration is a simple day count used for arithmetic with date, based on the Gregorian Calendar. Internally, it uses the datetime boost library to represent gregorian date duration, by using the data type boost::gregorian::date_duration.
Definition at line 59 of file DateDuration.h.
| te::dt::DateDuration::DateDuration | ( | ) |
Empty constructor.
Referenced by operator=().
| te::dt::DateDuration::DateDuration | ( | long | dd | ) |
Constructor.
| dd | A date duration in days. |
| te::dt::DateDuration::DateDuration | ( | const boost::gregorian::date_duration & | dd | ) |
Constructor.
| dd | A date duration. |
| te::dt::DateDuration::DateDuration | ( | const te::dt::DateDuration & | rhs | ) |
Copy Constructor.
|
virtual |
Destructor.
|
virtual |
| boost::gregorian::date_duration & te::dt::DateDuration::getDateDuration | ( | ) |
It returns the boost date duration type.
| const boost::gregorian::date_duration & te::dt::DateDuration::getDateDuration | ( | ) | const |
It returns the boost date duration type.
|
inlinevirtual |
It returns the subtype of the date and time type.
Implements te::dt::DateTime.
Definition at line 163 of file DateDuration.h.
References te::dt::DATE_DURATION.
|
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 date duration to be compared. |
Implements te::dt::DateTime.
References te::dt::DateTime::DateTime().
|
virtual |
Operator <.
| rhs | The right-hand-side date duration to be compared. |
Implements te::dt::DateTime.
References te::dt::DateTime::DateTime().
| DateDuration & te::dt::DateDuration::operator= | ( | const DateDuration & | date | ) |
Operator =.
| rhs | The date to be assigned. |
References DateDuration().
|
virtual |
Operator ==.
| rhs | The date duration to be compared. |
Implements te::dt::DateTime.
References te::dt::DateTime::DateTime().
|
virtual |
Operator >
| rhs | The right-hand-side date duration to be compared. |
Implements te::dt::DateTime.
References te::dt::DateTime::DateTime().
|
virtual |
It returns the date duration in a textual format.
Implements te::dt::AbstractData.
|
protected |
Date duration information.
Definition at line 172 of file DateDuration.h.