InitialTimeZoneRule represents a time zone rule representing a time zone effective from the beginning and has no actual start times.
More...
#include <tzrule.h>

Public Member Functions | |
| InitialTimeZoneRule (const UnicodeString &name, int32_t rawOffset, int32_t dstSavings) | |
Constructs an InitialTimeZoneRule with the name, the GMT offset of its standard time and the amount of daylight saving offset adjustment. | |
| InitialTimeZoneRule (const InitialTimeZoneRule &source) | |
| Copy constructor. | |
| virtual | ~InitialTimeZoneRule () |
| Destructor. | |
| virtual InitialTimeZoneRule * | clone (void) const |
| Clone this InitialTimeZoneRule object polymorphically. | |
| InitialTimeZoneRule & | operator= (const InitialTimeZoneRule &right) |
| Assignment operator. | |
| virtual UBool | operator== (const TimeZoneRule &that) const |
Return true if the given TimeZoneRule objects are semantically equal. | |
| virtual UBool | operator!= (const TimeZoneRule &that) const |
Return true if the given TimeZoneRule objects are semantically unequal. | |
| UBool | getStartInYear (int32_t year, int32_t prevRawOffset, int32_t prevDSTSavings, UDate &result) const |
| Gets the time when this rule takes effect in the given year. | |
| virtual UBool | isEquivalentTo (const TimeZoneRule &that) const |
| Returns if this rule represents the same rule and offsets as another. | |
| virtual UBool | getFirstStart (int32_t prevRawOffset, int32_t prevDSTSavings, UDate &result) const |
| Gets the very first time when this rule takes effect. | |
| virtual UBool | getFinalStart (int32_t prevRawOffset, int32_t prevDSTSavings, UDate &result) const |
| Gets the final time when this rule takes effect. | |
| virtual UBool | getNextStart (UDate base, int32_t prevRawOffset, int32_t prevDSTSavings, UBool inclusive, UDate &result) const |
| Gets the first time when this rule takes effect after the specified time. | |
| virtual UBool | getPreviousStart (UDate base, int32_t prevRawOffset, int32_t prevDSTSavings, UBool inclusive, UDate &result) const |
| Gets the most recent time when this rule takes effect before the specified time. | |
| virtual UClassID | getDynamicClassID (void) const |
| Returns a unique class ID POLYMORPHICALLY. | |
Static Public Member Functions | |
| static UClassID | getStaticClassID (void) |
| Return the class ID for this class. | |
InitialTimeZoneRule represents a time zone rule representing a time zone effective from the beginning and has no actual start times.
Definition at line 198 of file tzrule.h.
| InitialTimeZoneRule::InitialTimeZoneRule | ( | const UnicodeString & | name, | |
| int32_t | rawOffset, | |||
| int32_t | dstSavings | |||
| ) |
Constructs an InitialTimeZoneRule with the name, the GMT offset of its standard time and the amount of daylight saving offset adjustment.
| name | The time zone name. | |
| rawOffset | The UTC offset of its standard time in milliseconds. | |
| dstSavings | The amount of daylight saving offset adjustment in milliseconds. If this ia a rule for standard time, the value of this argument is 0. |
| InitialTimeZoneRule::InitialTimeZoneRule | ( | const InitialTimeZoneRule & | source | ) |
| virtual InitialTimeZoneRule::~InitialTimeZoneRule | ( | ) | [virtual] |
| virtual InitialTimeZoneRule* InitialTimeZoneRule::clone | ( | void | ) | const [virtual] |
Clone this InitialTimeZoneRule object polymorphically.
The caller owns the result and should delete it when done.
Implements TimeZoneRule.
| virtual UClassID InitialTimeZoneRule::getDynamicClassID | ( | void | ) | const [virtual] |
Returns a unique class ID POLYMORPHICALLY.
Pure virtual override. This method is to implement a simple version of RTTI, since not all C++ compilers support genuine RTTI. Polymorphic operator==() and clone() methods call this method.
Implements UObject.
| virtual UBool InitialTimeZoneRule::getFinalStart | ( | int32_t | prevRawOffset, | |
| int32_t | prevDSTSavings, | |||
| UDate & | result | |||
| ) | const [virtual] |
Gets the final time when this rule takes effect.
| prevRawOffset | The standard time offset from UTC before this rule takes effect in milliseconds. | |
| prevDSTSavings | The amount of daylight saving offset from the standard time. | |
| result | Receives the final time when this rule takes effect. |
Implements TimeZoneRule.
| virtual UBool InitialTimeZoneRule::getFirstStart | ( | int32_t | prevRawOffset, | |
| int32_t | prevDSTSavings, | |||
| UDate & | result | |||
| ) | const [virtual] |
Gets the very first time when this rule takes effect.
| prevRawOffset | The standard time offset from UTC before this rule takes effect in milliseconds. | |
| prevDSTSavings | The amount of daylight saving offset from the standard time. | |
| result | Receives the very first time when this rule takes effect. |
Implements TimeZoneRule.
| virtual UBool InitialTimeZoneRule::getNextStart | ( | UDate | base, | |
| int32_t | prevRawOffset, | |||
| int32_t | prevDSTSavings, | |||
| UBool | inclusive, | |||
| UDate & | result | |||
| ) | const [virtual] |
Gets the first time when this rule takes effect after the specified time.
| base | The first start time after this base time will be returned. | |
| prevRawOffset | The standard time offset from UTC before this rule takes effect in milliseconds. | |
| prevDSTSavings | The amount of daylight saving offset from the standard time. | |
| inclusive | Whether the base time is inclusive or not. | |
| result | Receives The first time when this rule takes effect after the specified base time. |
Implements TimeZoneRule.
| virtual UBool InitialTimeZoneRule::getPreviousStart | ( | UDate | base, | |
| int32_t | prevRawOffset, | |||
| int32_t | prevDSTSavings, | |||
| UBool | inclusive, | |||
| UDate & | result | |||
| ) | const [virtual] |
Gets the most recent time when this rule takes effect before the specified time.
| base | The most recent time before this base time will be returned. | |
| prevRawOffset | The standard time offset from UTC before this rule takes effect in milliseconds. | |
| prevDSTSavings | The amount of daylight saving offset from the standard time. | |
| inclusive | Whether the base time is inclusive or not. | |
| result | Receives The most recent time when this rule takes effect before the specified base time. |
Implements TimeZoneRule.
| UBool InitialTimeZoneRule::getStartInYear | ( | int32_t | year, | |
| int32_t | prevRawOffset, | |||
| int32_t | prevDSTSavings, | |||
| UDate & | result | |||
| ) | const |
Gets the time when this rule takes effect in the given year.
| year | The Gregorian year, with 0 == 1 BCE, -1 == 2 BCE, etc. | |
| prevRawOffset | The standard time offset from UTC before this rule takes effect in milliseconds. | |
| prevDSTSavings | The amount of daylight saving offset from the standard time. | |
| result | Receives the start time in the year. |
| static UClassID InitialTimeZoneRule::getStaticClassID | ( | void | ) | [static] |
Return the class ID for this class.
This is useful only for comparing to a return value from getDynamicClassID(). For example:
. Base* polymorphic_pointer = createPolymorphicObject(); . if (polymorphic_pointer->getDynamicClassID() == . erived::getStaticClassID()) ...
| virtual UBool InitialTimeZoneRule::isEquivalentTo | ( | const TimeZoneRule & | that | ) | const [virtual] |
Returns if this rule represents the same rule and offsets as another.
When two TimeZoneRule objects differ only its names, this method returns true.
| that | The TimeZoneRule object to be compared with. |
TimeZoneRule is equivalent to this one. Reimplemented from TimeZoneRule.
| virtual UBool InitialTimeZoneRule::operator!= | ( | const TimeZoneRule & | that | ) | const [virtual] |
Return true if the given TimeZoneRule objects are semantically unequal.
Objects of different subclasses are considered unequal.
| that | The object to be compared with. |
TimeZoneRule objects are semantically unequal. Reimplemented from TimeZoneRule.
| InitialTimeZoneRule& InitialTimeZoneRule::operator= | ( | const InitialTimeZoneRule & | right | ) |
| virtual UBool InitialTimeZoneRule::operator== | ( | const TimeZoneRule & | that | ) | const [virtual] |
Return true if the given TimeZoneRule objects are semantically equal.
Objects of different subclasses are considered unequal.
| that | The object to be compared with. |
TimeZoneRule objects are semantically equal. Reimplemented from TimeZoneRule.
1.5.7.1