umtx_lock(&astroLock);
{
if (!gChineseCalendarZoneAstroCalcInitialized) {
- gChineseCalendarZoneAstroCalc = new SimpleTimeZone(CHINA_OFFSET, UnicodeString("CHINA_ZONE") );
+ gChineseCalendarZoneAstroCalc = new SimpleTimeZone(CHINA_OFFSET, UNICODE_STRING_SIMPLE("CHINA_ZONE") );
gChineseCalendarZoneAstroCalcInitialized = TRUE;
ucln_i18n_registerCleanup(UCLN_I18N_CHINESE_CALENDAR, calendar_chinese_cleanup);
}
const UDate millis1897[] = { (UDate)((1897 - 1970) * 365 * kOneDay) }; // some days of error is not a problem here
const UDate millis1898[] = { (UDate)((1898 - 1970) * 365 * kOneDay) }; // some days of error is not a problem here
const UDate millis1912[] = { (UDate)((1912 - 1970) * 365 * kOneDay) }; // this doesn't create an issue for 1911/12/20
- InitialTimeZoneRule* initialTimeZone = new InitialTimeZoneRule(UnicodeString("GMT+8"), 8*kOneHour, 0);
- TimeZoneRule* rule1897 = new TimeArrayTimeZoneRule(UnicodeString("Korean 1897"), 7*kOneHour, 0, millis1897, 1, DateTimeRule::STANDARD_TIME);
- TimeZoneRule* rule1898to1911 = new TimeArrayTimeZoneRule(UnicodeString("Korean 1898-1911"), 8*kOneHour, 0, millis1898, 1, DateTimeRule::STANDARD_TIME);
- TimeZoneRule* ruleFrom1912 = new TimeArrayTimeZoneRule(UnicodeString("Korean 1912-"), 9*kOneHour, 0, millis1912, 1, DateTimeRule::STANDARD_TIME);
+ InitialTimeZoneRule* initialTimeZone = new InitialTimeZoneRule(UNICODE_STRING_SIMPLE("GMT+8"), 8*kOneHour, 0);
+ TimeZoneRule* rule1897 = new TimeArrayTimeZoneRule(UNICODE_STRING_SIMPLE("Korean 1897"), 7*kOneHour, 0, millis1897, 1, DateTimeRule::STANDARD_TIME);
+ TimeZoneRule* rule1898to1911 = new TimeArrayTimeZoneRule(UNICODE_STRING_SIMPLE("Korean 1898-1911"), 8*kOneHour, 0, millis1898, 1, DateTimeRule::STANDARD_TIME);
+ TimeZoneRule* ruleFrom1912 = new TimeArrayTimeZoneRule(UNICODE_STRING_SIMPLE("Korean 1912-"), 9*kOneHour, 0, millis1912, 1, DateTimeRule::STANDARD_TIME);
UErrorCode status = U_ZERO_ERROR;
- RuleBasedTimeZone* dangiCalZoneAstroCalc = new RuleBasedTimeZone(UnicodeString("KOREA_ZONE"), initialTimeZone); // adopts initialTimeZone
+ RuleBasedTimeZone* dangiCalZoneAstroCalc = new RuleBasedTimeZone(UNICODE_STRING_SIMPLE("KOREA_ZONE"), initialTimeZone); // adopts initialTimeZone
dangiCalZoneAstroCalc->addTransitionRule(rule1897, status); // adopts rule1897
dangiCalZoneAstroCalc->addTransitionRule(rule1898to1911, status);
dangiCalZoneAstroCalc->addTransitionRule(ruleFrom1912, status);
Mutex m(&gInitMutex);
UErrorCode status = U_ZERO_ERROR;
if (gInclusionSet == NULL) {
- gInclusionSet = new UnicodeSet(UnicodeString("["
+ gInclusionSet = new UnicodeSet(UNICODE_STRING_SIMPLE("["
"\\-.\\u00B7\\u05F3\\u05F4\\u0F0B\\u200C\\u200D\\u2019]"), status);
- gRecommendedSet = new UnicodeSet(UnicodeString("["
+ gRecommendedSet = new UnicodeSet(UNICODE_STRING_SIMPLE("["
"[0-z\\u00C0-\\u017E\\u01A0\\u01A1\\u01AF\\u01B0\\u01CD-"
"\\u01DC\\u01DE-\\u01E3\\u01E6-\\u01F5\\u01F8-\\u021B\\u021E"
"\\u021F\\u0226-\\u0233\\u02BB\\u02BC\\u02EC\\u0300-\\u0304"