Lines Matching refs:DateTimeRule
160 DateTimeRule *dtr;
171 dtr = new DateTimeRule(UCAL_SEPTEMBER, 30, UCAL_SATURDAY, FALSE,
172 1*HOUR, DateTimeRule::WALL_TIME); // SUN<=30 in September, at 1AM wall time
180 dtr = new DateTimeRule(UCAL_FEBRUARY, 2, UCAL_SUNDAY,
181 1*HOUR, DateTimeRule::WALL_TIME); // 2nd Sunday in February, at 1AM wall time
196 dtr = new DateTimeRule(UCAL_SEPTEMBER, -1, UCAL_SATURDAY,
197 1*HOUR, DateTimeRule::WALL_TIME); // Last Sunday in September at 1AM wall time
203 dtr = new DateTimeRule(UCAL_FEBRUARY, 8, UCAL_SUNDAY, true,
204 1*HOUR, DateTimeRule::WALL_TIME); // SUN>=8 in February, at 1AM wall time
217 dtr = new DateTimeRule(UCAL_SEPTEMBER, 30, UCAL_SATURDAY, false,
218 2*HOUR, DateTimeRule::UTC_TIME);
224 dtr = new DateTimeRule(UCAL_FEBRUARY, 2, UCAL_SUNDAY,
225 0*HOUR, DateTimeRule::STANDARD_TIME);
397 dtr = new DateTimeRule(UCAL_OCTOBER, 15, 1*HOUR, DateTimeRule::WALL_TIME);
438 DateTimeRule *dtr;
442 dtr = new DateTimeRule(UCAL_OCTOBER, -1, UCAL_SUNDAY,
443 2*HOUR, DateTimeRule::WALL_TIME); // Last Sunday in October, at 2AM wall time
450 dtr = new DateTimeRule(UCAL_NOVEMBER, 1, UCAL_SUNDAY,
451 true, 2*HOUR, DateTimeRule::WALL_TIME); // SUN>=1 in November, at 2AM wall time
459 dtr = new DateTimeRule(UCAL_APRIL, -1, UCAL_SUNDAY,
460 2*HOUR, DateTimeRule::WALL_TIME); // Last Sunday in April, at 2AM wall time
467 dtr = new DateTimeRule(UCAL_JANUARY, 6,
468 DateTimeRule::WALL_TIME); // January 6, at 2AM wall time
475 dtr = new DateTimeRule(UCAL_FEBRUARY, 23,
476 2*HOUR, DateTimeRule::WALL_TIME); // February 23, at 2AM wall time
483 dtr = new DateTimeRule(UCAL_APRIL, -1, UCAL_SUNDAY,
484 2*HOUR, DateTimeRule::WALL_TIME); // Last Sunday in April, at 2AM wall time
491 dtr = new DateTimeRule(UCAL_APRIL, 1, UCAL_SUNDAY,
492 true, 2*HOUR, DateTimeRule::WALL_TIME); // SUN>=1 in April, at 2AM wall time
499 dtr = new DateTimeRule(UCAL_MARCH, 8, UCAL_SUNDAY,
500 true, 2*HOUR, DateTimeRule::WALL_TIME); // SUN>=8 in March, at 2AM wall time
1145 const DateTimeRule *dtr = std->getRule();
1146 if (dtr->getDateRuleType() != DateTimeRule::DOW) {
1147 errln("FAIL: simple std rull must use DateTimeRule::DOW as date rule.");
1150 if (dtr->getTimeRuleType() != DateTimeRule::WALL_TIME) {
1151 errln("FAIL: simple std rull must use DateTimeRule::WALL_TIME as time rule.");
1155 if (dtr->getDateRuleType() != DateTimeRule::DOW) {
1156 errln("FAIL: simple dst rull must use DateTimeRule::DOW as date rule.");
1159 if (dtr->getTimeRuleType() != DateTimeRule::WALL_TIME) {
1160 errln("FAIL: simple dst rull must use DateTimeRule::WALL_TIME as time rule.");
1208 DateTimeRule *dtr1 = new DateTimeRule(UCAL_FEBRUARY, 29, UCAL_SUNDAY, FALSE,
1209 3*HOUR, DateTimeRule::WALL_TIME); // Last Sunday on or before Feb 29, at 3 AM, wall time
1210 DateTimeRule *dtr2 = new DateTimeRule(UCAL_MARCH, 11, 2*HOUR,
1211 DateTimeRule::STANDARD_TIME); // Mar 11, at 2 AM, standard time
1212 DateTimeRule *dtr3 = new DateTimeRule(UCAL_OCTOBER, -1, UCAL_SATURDAY,
1213 6*HOUR, DateTimeRule::UTC_TIME); //Last Saturday in Oct, at 6 AM, UTC
1214 DateTimeRule *dtr4 = new DateTimeRule(UCAL_MARCH, 8, UCAL_SUNDAY, TRUE,
1215 2*HOUR, DateTimeRule::WALL_TIME); // First Sunday on or after Mar 8, at 2 AM, wall time
1231 TimeArrayTimeZoneRule *t1 = new TimeArrayTimeZoneRule("t1", -3*HOUR, 0, trtimes1, 1, DateTimeRule::UTC_TIME);
1232 TimeArrayTimeZoneRule *t2 = new TimeArrayTimeZoneRule("t2", -3*HOUR, 0, trtimes1, 1, DateTimeRule::UTC_TIME);
1233 TimeArrayTimeZoneRule *t3 = new TimeArrayTimeZoneRule("t3", -3*HOUR, 0, trtimes2, 2, DateTimeRule::UTC_TIME);
1234 TimeArrayTimeZoneRule *t4 = new TimeArrayTimeZoneRule("t4", -3*HOUR, 0, trtimes1, 1, DateTimeRule::STANDARD_TIME);
1235 TimeArrayTimeZoneRule *t5 = new TimeArrayTimeZoneRule("t5", -4*HOUR, 1*HOUR, trtimes1, 1, DateTimeRule::WALL_TIME);
1237 // DateTimeRule::operator=/clone
1238 DateTimeRule dtr0(UCAL_MAY, 31, 2*HOUR, DateTimeRule::WALL_TIME);
1240 errln("FAIL: DateTimeRule dtr0 is not equal to dtr1, but got wrong result");
1244 errln("FAIL: DateTimeRule dtr0 is equal to dtr1, but got wrong result");
1246 DateTimeRule
1248 errln("FAIL: DateTimeRule dtr0c is equal to dtr1, but got wrong result");
1269 errln("FAIL: The same DateTimeRule must be returned from AnnualTimeZoneRule a1 and a2");
1398 TimeArrayTimeZoneRule t0("t0", 4*HOUR, 0, trtimes1, 1, DateTimeRule::UTC_TIME);
1432 if (t1->getTimeType() != DateTimeRule::UTC_TIME) {
1435 if (t4->getTimeType() != DateTimeRule::STANDARD_TIME) {
1438 if (t5->getTimeType() != DateTimeRule::WALL_TIME) {
2630 DateTimeRule *dtRule = new DateTimeRule(UCAL_OCTOBER, -1, UCAL_SUNDAY, 10800000, DateTimeRule::WALL_TIME);
2634 dtRule = new DateTimeRule(UCAL_MARCH, -1, UCAL_SUNDAY, 7200000, DateTimeRule::WALL_TIME);
2638 dtRule = new DateTimeRule(UCAL_JANUARY, 1, 0, DateTimeRule::WALL_TIME);
2642 dtRule = new DateTimeRule(UCAL_JANUARY, 1, 1, DateTimeRule::WALL_TIME);