src/server/DataType.cxx File Reference

#include <os.h>
#include <DataType.h>

Include dependency graph for DataType.cxx:

Go to the source code of this file.

Defines

#define SmallestValJulDate   (1721426)
#define MAX_VALID_SECONDS   (60 * 60 * 24 -1)

Functions

Date operator+ (const Date &d1, int days)
Date operator+ (int days, const Date &d1)
Date operator- (const Date &d1, int days)
int operator- (const Date &d1, const Date &d2)
int operator< (const Date &d1, const Date &d2)
int operator> (const Date &d1, const Date &d2)
int operator<= (const Date &d1, const Date &d2)
int operator>= (const Date &d1, const Date &d2)
int operator== (const Date &d1, const Date &d2)
int operator!= (const Date &d1, const Date &d2)
Time operator+ (const Time &t1, int seconds)
Time operator+ (int seconds, const Time &t1)
Time operator- (const Time &t1, int seconds)
int operator- (const Time &t1, const Time &t2)
int operator< (const Time &t1, const Time &t2)
int operator> (const Time &t1, const Time &t2)
int operator<= (const Time &t1, const Time &t2)
int operator>= (const Time &t1, const Time &t2)
int operator== (const Time &t1, const Time &t2)
int operator!= (const Time &t1, const Time &t2)
int operator< (const TimeStamp &d1, const TimeStamp &d2)
int operator> (const TimeStamp &d1, const TimeStamp &d2)
int operator<= (const TimeStamp &d1, const TimeStamp &d2)
int operator>= (const TimeStamp &d1, const TimeStamp &d2)
int operator== (const TimeStamp &d1, const TimeStamp &d2)
int operator!= (const TimeStamp &d1, const TimeStamp &d2)

Variables

static const char * day_names []
static const char * day_abbrs []
static const char * month_names []
static const char * month_abbrs []
static int daysBeforeMonth []
static int days_per_month []


Define Documentation

#define MAX_VALID_SECONDS   (60 * 60 * 24 -1)

Definition at line 206 of file DataType.cxx.

Referenced by Time::isValid().

#define SmallestValJulDate   (1721426)

Definition at line 19 of file DataType.cxx.

Referenced by Date::isValid(), and Date::julianToYMD().


Function Documentation

int operator!= ( const TimeStamp d1,
const TimeStamp d2 
)

Definition at line 322 of file DataType.cxx.

References TimeStamp::date, and TimeStamp::time.

00323     { return d1.date != d2.date && d1.time != d2.time; }

int operator!= ( const Time t1,
const Time t2 
)

Definition at line 277 of file DataType.cxx.

References Time::timeVal.

00278     { return t1.timeVal != t2.timeVal; }

int operator!= ( const Date d1,
const Date d2 
)

Definition at line 121 of file DataType.cxx.

References Date::julianDate.

00122     { return d1.julianDate != d2.julianDate; }

Time operator+ ( int  seconds,
const Time t1 
)

Definition at line 259 of file DataType.cxx.

References Time::timeVal.

00260     { return Time(t1.timeVal + seconds*10000); }

Time operator+ ( const Time t1,
int  seconds 
)

Definition at line 257 of file DataType.cxx.

References Time::timeVal.

00258     { return Time(t1.timeVal + seconds*10000); }

Date operator+ ( int  days,
const Date d1 
)

Definition at line 103 of file DataType.cxx.

References Date::julianDate.

00104     { return Date(d1.julianDate + days); }

Date operator+ ( const Date d1,
int  days 
)

Definition at line 101 of file DataType.cxx.

References Date::julianDate.

00102     { return Date(d1.julianDate + days); }

int operator- ( const Time t1,
const Time t2 
)

Definition at line 264 of file DataType.cxx.

References Time::timeVal.

00265     { return (t1.timeVal - t2.timeVal)/10000; }

Time operator- ( const Time t1,
int  seconds 
)

Definition at line 261 of file DataType.cxx.

References Time::timeVal.

00262     { return Time(t1.timeVal - seconds*10000); }

int operator- ( const Date d1,
const Date d2 
)

Definition at line 108 of file DataType.cxx.

References Date::julianDate.

00109     { return d1.julianDate - d2.julianDate; }

Date operator- ( const Date d1,
int  days 
)

Definition at line 105 of file DataType.cxx.

References Date::julianDate.

00106     { return Date(d1.julianDate - days); }

int operator< ( const TimeStamp d1,
const TimeStamp d2 
)

Definition at line 312 of file DataType.cxx.

References TimeStamp::date, and TimeStamp::time.

00313     { return (d1.date != d2.date) ? d1.date < d2.date : d1.time < d2.time; }

int operator< ( const Time t1,
const Time t2 
)

Definition at line 267 of file DataType.cxx.

References Time::timeVal.

00268     { return t1.timeVal < t2.timeVal; }

int operator< ( const Date d1,
const Date d2 
)

Definition at line 111 of file DataType.cxx.

References Date::julianDate.

00112     { return d1.julianDate < d2.julianDate; }

int operator<= ( const TimeStamp d1,
const TimeStamp d2 
)

Definition at line 316 of file DataType.cxx.

References TimeStamp::date, and TimeStamp::time.

00317     { return (d1.date != d2.date) ? d1.date < d2.date : d1.time <= d2.time; }

int operator<= ( const Time t1,
const Time t2 
)

Definition at line 271 of file DataType.cxx.

References Time::timeVal.

00272     { return t1.timeVal <= t2.timeVal; }

int operator<= ( const Date d1,
const Date d2 
)

Definition at line 115 of file DataType.cxx.

References Date::julianDate.

00116     { return d1.julianDate <= d2.julianDate; }

int operator== ( const TimeStamp d1,
const TimeStamp d2 
)

Definition at line 320 of file DataType.cxx.

References TimeStamp::date, and TimeStamp::time.

00321     { return d1.date == d2.date && d1.time == d2.time; }

int operator== ( const Time t1,
const Time t2 
)

Definition at line 275 of file DataType.cxx.

References Time::timeVal.

00276     { return t1.timeVal == t2.timeVal; }

int operator== ( const Date d1,
const Date d2 
)

Definition at line 119 of file DataType.cxx.

References Date::julianDate.

00120     { return d1.julianDate == d2.julianDate; }

int operator> ( const TimeStamp d1,
const TimeStamp d2 
)

Definition at line 314 of file DataType.cxx.

References TimeStamp::date, and TimeStamp::time.

00315     { return (d1.date != d2.date) ? d1.date > d2.date : d1.time > d2.time; }

int operator> ( const Time t1,
const Time t2 
)

Definition at line 269 of file DataType.cxx.

References Time::timeVal.

00270     { return t1.timeVal > t2.timeVal; }

int operator> ( const Date d1,
const Date d2 
)

Definition at line 113 of file DataType.cxx.

References Date::julianDate.

00114     { return d1.julianDate > d2.julianDate; }

int operator>= ( const TimeStamp d1,
const TimeStamp d2 
)

Definition at line 318 of file DataType.cxx.

References TimeStamp::date, and TimeStamp::time.

00319     { return (d1.date != d2.date) ? d1.date > d2.date : d1.time >= d2.time; }

int operator>= ( const Time t1,
const Time t2 
)

Definition at line 273 of file DataType.cxx.

References Time::timeVal.

00274     { return t1.timeVal >= t2.timeVal; }

int operator>= ( const Date d1,
const Date d2 
)

Definition at line 117 of file DataType.cxx.

References Date::julianDate.

00118     { return d1.julianDate >= d2.julianDate; }


Variable Documentation

const char* day_abbrs[] [static]

Initial value:

 {
    "Sun",    "Mon",    "Tue",     "Wed",       "Thu",      "Fri",    "Sat"
}

Definition at line 68 of file DataType.cxx.

Referenced by Date::dayOfWeekAbbr().

const char* day_names[] [static]

Initial value:

 {
    "Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"
}

Definition at line 65 of file DataType.cxx.

Referenced by Date::dayOfWeekName().

int days_per_month[] [static]

Initial value:

 {
    31, 28, 31,  30,   31, 30,  31,  31,  30,  31,  30,  31
}

Definition at line 85 of file DataType.cxx.

Referenced by Date::daysInMonth().

int daysBeforeMonth[] [static]

Initial value:

 {
0,  31, 59, 90, 120, 151, 181, 212, 243, 273, 304, 334, 365
}

Definition at line 82 of file DataType.cxx.

Referenced by Date::dayOfYear().

const char* month_abbrs[] [static]

Initial value:

 {
    "Jan",     "Feb",      "Mar",      "Apr",     "May",      "Jun",
    "Jul",     "Aug",      "Sep",      "Oct",     "Nov",      "Dec"
}

Definition at line 76 of file DataType.cxx.

Referenced by Date::monthAbbr().

const char* month_names[] [static]

Initial value:

 {
    "January", "February", "March",     "April",   "May",      "June",
    "July",    "August",   "September", "October", "November", "December"
}

Definition at line 72 of file DataType.cxx.

Referenced by Date::monthName().


Generated on Mon Jun 9 22:41:34 2008 for csql by  doxygen 1.4.7