Inheritance diagram for sword::CalendarWestern:

Public Methods | |
| virtual void | convert (Time time, word &day, word &month, word &year, word &hour, word &minute, word &second, word &millisecond) const |
| Converts a timestamp into a full 'dmy h:m:s' date value. | |
| virtual void | convert (Time time, word &day, word &month, word &year) const |
| Converts a timestamp into a 'dmy' date value. | |
| virtual Time | convert (word day, word month, word year, word hour, word minute, word second, word millisecond) const |
| Converts a full 'dmy h:m:s' date value into a timestamp. | |
| virtual Time | convert (word day, word month, word year) const |
| Converts a 'dmy' date value into a timestamp (assuming hour is 0:0:0). | |
| virtual bool | isLeapYear (word year) const=0 |
| Checks whether a year is a leap year or not. | |
| virtual int64 | daysInMonth (word month, word year) const=0 |
| Computes the number of days in a month. | |
| virtual int64 | daysInYear (word year) const=0 |
| Computes the number of days in a year. | |
| virtual int64 | daysWithinYear (word day, word month, word year) const=0 |
| Computes the number of this day within its year (Jan 1st returns 0). | |
| virtual int64 | daysBeforeYear (word year) const=0 |
| Number of days from 1/1/1601 to 1/1/year. | |
| virtual word | weekDay (Time time) const=0 |
| Computes the day of the week (0=Sunday to 6=Saturday). | |
| virtual Time | easter (word year) const=0 |
| Computes the easter date for a given year. | |
| virtual bool | isValid (word day, word month, word year, word hour, word minute, word second, word millisecond) const=0 |
| Validates a 'dmy h:m:s' date value within this Calendar. | |
| virtual int64 | dmy2days_ (word day, word month, word year) const=0 |
| Number of days to day/month/year. | |
| virtual void | days2dmy_ (int64 days, word &day, word &month, word &year) const=0 |
| Computes the day/month/year from the number of days. | |
All western-culture calendars assume the same basic calendar structure, as follows, but may differ on other aspects such as the precise definition of the leap years. This class must not be used, it is only a base class.
|
||||||||||||||||
|
Converts a 'dmy' date value into a timestamp (assuming hour is 0:0:0).
Implements sword::Calendar. |
|
||||||||||||||||||||||||||||||||
|
Converts a full 'dmy h:m:s' date value into a timestamp.
Implements sword::Calendar. |
|
||||||||||||||||||||
|
Converts a timestamp into a 'dmy' date value.
Implements sword::Calendar. |
|
||||||||||||||||||||||||||||||||||||
|
Converts a timestamp into a full 'dmy h:m:s' date value.
Implements sword::Calendar. |
|
||||||||||||||||||||
|
Computes the day/month/year from the number of days.
Implemented in sword::CalendarGregorian, and sword::CalendarJulian. |
|
|
Number of days from 1/1/1601 to 1/1/year.
Implemented in sword::CalendarGregorian, and sword::CalendarJulian. |
|
||||||||||||
|
Computes the number of days in a month.
Implemented in sword::CalendarGregorian, and sword::CalendarJulian. |
|
|
Computes the number of days in a year.
Implemented in sword::CalendarGregorian, and sword::CalendarJulian. |
|
||||||||||||||||
|
Computes the number of this day within its year (Jan 1st returns 0).
Implemented in sword::CalendarGregorian, and sword::CalendarJulian. |
|
||||||||||||||||
|
Number of days to day/month/year.
Implemented in sword::CalendarGregorian, and sword::CalendarJulian. |
|
|
Computes the easter date for a given year.
Implemented in sword::CalendarGregorian, and sword::CalendarJulian. |
|
|
Checks whether a year is a leap year or not.
Implemented in sword::CalendarGregorian, and sword::CalendarJulian. |
|
||||||||||||||||||||||||||||||||
|
Validates a 'dmy h:m:s' date value within this Calendar.
Implemented in sword::CalendarGregorian, and sword::CalendarJulian. |
|
|
Computes the day of the week (0=Sunday to 6=Saturday).
Implemented in sword::CalendarGregorian, and sword::CalendarJulian. |
1.3-rc2