Lines Matching refs:DateTimeRule
162 DateTimeRule *dtr;
173 dtr = new DateTimeRule(UCAL_SEPTEMBER, 30, UCAL_SATURDAY, FALSE,
174 1*HOUR, DateTimeRule::WALL_TIME); // SUN<=30 in September, at 1AM wall time
182 dtr = new DateTimeRule(UCAL_FEBRUARY, 2, UCAL_SUNDAY,
183 1*HOUR, DateTimeRule::WALL_TIME); // 2nd Sunday in February, at 1AM wall time
198 dtr = new DateTimeRule(UCAL_SEPTEMBER, -1, UCAL_SATURDAY,
199 1*HOUR, DateTimeRule::WALL_TIME); // Last Sunday in September at 1AM wall time
205 dtr = new DateTimeRule(UCAL_FEBRUARY, 8, UCAL_SUNDAY, true,
206 1*HOUR, DateTimeRule::WALL_TIME); // SUN>=8 in February, at 1AM wall time
219 dtr = new DateTimeRule(UCAL_SEPTEMBER, 30, UCAL_SATURDAY, false,
220 2*HOUR, DateTimeRule::UTC_TIME);
226 dtr = new DateTimeRule(UCAL_FEBRUARY, 2, UCAL_SUNDAY,
227 0*HOUR, DateTimeRule::STANDARD_TIME);
399 dtr = new DateTimeRule(UCAL_OCTOBER, 15, 1*HOUR, DateTimeRule::WALL_TIME);
440 DateTimeRule *dtr;
444 dtr = new DateTimeRule(UCAL_OCTOBER, -1, UCAL_SUNDAY,
445 2*HOUR, DateTimeRule::WALL_TIME); // Last Sunday in October, at 2AM wall time
452 dtr = new DateTimeRule(UCAL_NOVEMBER, 1, UCAL_SUNDAY,
453 true, 2*HOUR, DateTimeRule::WALL_TIME); // SUN>=1 in November, at 2AM wall time
461 dtr = new DateTimeRule(UCAL_APRIL, -1, UCAL_SUNDAY,
462 2*HOUR, DateTimeRule::WALL_TIME); // Last Sunday in April, at 2AM wall time
469 DateTimeRule(UCAL_JANUARY, 6,
470 2*HOUR, DateTimeRule::WALL_TIME); // January 6, at 2AM wall time
477 dtr = new DateTimeRule(UCAL_FEBRUARY, 23,
478 2*HOUR, DateTimeRule::WALL_TIME); // February 23, at 2AM wall time
485 dtr = new DateTimeRule(UCAL_APRIL, -1, UCAL_SUNDAY,
486 2*HOUR, DateTimeRule::WALL_TIME); // Last Sunday in April, at 2AM wall time
493 dtr = new DateTimeRule(UCAL_APRIL, 1, UCAL_SUNDAY,
494 true, 2*HOUR, DateTimeRule::WALL_TIME); // SUN>=1 in April, at 2AM wall time
501 dtr = new DateTimeRule(UCAL_MARCH, 8, UCAL_SUNDAY,
502 true, 2*HOUR, DateTimeRule::WALL_TIME); // SUN>=8 in March, at 2AM wall time
1147 const DateTimeRule *dtr = std->getRule();
1148 if (dtr->getDateRuleType() != DateTimeRule::DOW) {
1149 errln("FAIL: simple std rull must use DateTimeRule::DOW as date rule.");
1152 if (dtr->getTimeRuleType() != DateTimeRule::WALL_TIME) {
1153 errln("FAIL: simple std rull must use DateTimeRule::WALL_TIME as time rule.");
1157 if (dtr->getDateRuleType() != DateTimeRule::DOW) {
1158 errln("FAIL: simple dst rull must use DateTimeRule::DOW as date rule.");
1161 if (dtr->getTimeRuleType() != DateTimeRule::WALL_TIME) {
1162 errln("FAIL: simple dst rull must use DateTimeRule::WALL_TIME as time rule.");
1210 DateTimeRule *dtr1 = new DateTimeRule(UCAL_FEBRUARY, 29, UCAL_SUNDAY, FALSE,
1211 3*HOUR, DateTimeRule::WALL_TIME); // Last Sunday on or before Feb 29, at 3 AM, wall time
1212 DateTimeRule *dtr2 = new DateTimeRule(UCAL_MARCH, 11, 2*HOUR,
1213 DateTimeRule::STANDARD_TIME); // Mar 11, at 2 AM, standard time
1214 DateTimeRule *dtr3 = new DateTimeRule(UCAL_OCTOBER, -1, UCAL_SATURDAY,
1215 6*HOUR, DateTimeRule::UTC_TIME); //Last Saturday in Oct, at 6 AM, UTC
1216 DateTimeRule *dtr4 = new DateTimeRule(UCAL_MARCH, 8, UCAL_SUNDAY, TRUE,
1217 2*HOUR, DateTimeRule::WALL_TIME); // First Sunday on or after Mar 8, at 2 AM, wall time
1233 TimeArrayTimeZoneRule *t1 = new TimeArrayTimeZoneRule("t1", -3*HOUR, 0, trtimes1, 1, DateTimeRule::UTC_TIME);
1234 TimeArrayTimeZoneRule *t2 = new TimeArrayTimeZoneRule("t2", -3*HOUR, 0, trtimes1, 1, DateTimeRule::UTC_TIME);
1235 TimeArrayTimeZoneRule *t3 = new TimeArrayTimeZoneRule("t3", -3*HOUR, 0, trtimes2, 2, DateTimeRule::UTC_TIME);
1236 TimeArrayTimeZoneRule *t4 = new TimeArrayTimeZoneRule("t4", -3*HOUR, 0, trtimes1, 1, DateTimeRule::STANDARD_TIME);
1237 TimeArrayTimeZoneRule *t5 = new TimeArrayTimeZoneRule("t5", -4*HOUR, 1*HOUR, trtimes1, 1, DateTimeRule::WALL_TIME);
1239 // DateTimeRule::operator=/clone
1240 DateTimeRule dtr0(UCAL_MAY, 31, 2*HOUR, DateTimeRule::WALL_TIME);
1242 errln("FAIL: DateTimeRule dtr0 is not equal to dtr1, but got wrong result");
1246 errln("FAIL: DateTimeRule
1248 DateTimeRule *dtr0c = dtr0.clone();
1250 errln("FAIL: DateTimeRule dtr0c is equal to dtr1, but got wrong result");
1271 errln("FAIL: The same DateTimeRule must be returned from AnnualTimeZoneRule a1 and a2");
1400 TimeArrayTimeZoneRule t0("t0", 4*HOUR, 0, trtimes1, 1, DateTimeRule::UTC_TIME);
1434 if (t1->getTimeType() != DateTimeRule::UTC_TIME) {
1437 if (t4->getTimeType() != DateTimeRule::STANDARD_TIME) {
1440 if (t5->getTimeType() != DateTimeRule::WALL_TIME) {
2632 DateTimeRule *dtRule = new DateTimeRule(UCAL_OCTOBER, -1, UCAL_SUNDAY, 10800000, DateTimeRule::WALL_TIME);
2636 dtRule = new DateTimeRule(UCAL_MARCH, -1, UCAL_SUNDAY, 7200000, DateTimeRule::WALL_TIME);
2640 dtRule = new DateTimeRule(UCAL_JANUARY, 1, 0, DateTimeRule::WALL_TIME);
2644 dtRule = new DateTimeRule(UCAL_JANUARY, 1, 1, DateTimeRule::WALL_TIME);