SAInterval
This is MySQL specific class that is used to represent MySQL TIME data type. More...
Public Member Functions | |
SAInterval () | |
Default constructor, initializes to zero. | |
SAInterval (double dVal) | |
Initializes from double. | |
SAInterval (int nDays, int nHours, int nMins, int nSecs) | |
Initializes with defined days, hours, minutes and seconds. | |
SAInterval (int nDays, int nHours, int nMins, int nSecs, unsigned int nNanoSeconds) | |
Initializes with defined days, hours, minutes, seconds and nanoseconds. | |
double | GetTotalDays () const |
Returns total days in interval. | |
double | GetTotalHours () const |
Returns total hours in interval. | |
double | GetTotalMinutes () const |
Returns total minutes in interval. | |
double | GetTotalSeconds () const |
Returns total seconds in interval. | |
int | GetDays () const |
Returns interval days. | |
int | GetHours () const |
Returns interval hours. | |
int | GetMinutes () const |
Returns interval minutes. | |
int | GetSeconds () const |
Returns interval seconds. | |
unsigned int | Fraction () const |
Returns interval nanoseconds. | |
operator double () const | |
Converts interval into double. More... | |
operator SAString () const | |
Converts interval into string (format is [-]HH:MM:SS[.ZZZZZZZZZ]) | |
void | SetInterval (int nDays, int nHours, int nMins, int nSecs, unsigned int nNanoSeconds) |
Re-initializes with defined days, hours, minutes, seconds and nanoseconds. | |
SAInterval & | operator= (double dVal) |
Re-initializes from double. | |
SAInterval | operator+ (const SAInterval &interval) const |
Interval type operator. | |
SAInterval | operator- (const SAInterval &interval) const |
Interval type operator. | |
SAInterval & | operator+= (const SAInterval interval) |
Interval type operator. | |
SAInterval & | operator-= (const SAInterval interval) |
Interval type operator. | |
SAInterval | operator- () const |
Interval type operator. | |
Detailed Description
This is MySQL specific class that is used to represent MySQL TIME data type.
This class also can be used with SADateTime to represent the difference between two dates.
Member Function Documentation
◆ operator double()
SAInterval::operator double | ( | ) | const |
Converts interval into double.