Lines Matching refs:ec
1003 UErrorCode ec = U_ZERO_ERROR;
1018 SimpleDateFormat ref(pattern, loc, ec);
1019 if (U_FAILURE(ec)) {
1020 dataerrln("contruct SimpleDateFormat in expect failed: %s", u_errorName(ec));
1030 UDate date = ref.parse(ctou(datestr), ec);
1031 if (!assertSuccess("parse 1st data in expect", ec)) return;
1032 UDate date_2 = ref.parse(ctou(datestr_2), ec);
1033 if (!assertSuccess("parse 2nd data in expect", ec)) return;
1038 DateIntervalFormat* dtitvfmt = DateIntervalFormat::createInstance(oneSkeleton, loc, ec);
1039 if (!assertSuccess("createInstance(skeleton) in expect", ec)) return;
1041 dtitvfmt->format(&dtitv, str.remove(), pos, ec);
1042 if (!assertSuccess("format in expect", ec)) return;
1125 UErrorCode ec = U_ZERO_ERROR;
1132 SimpleDateFormat ref(pattern, loc, ec);
1133 if (U_FAILURE(ec)) {
1134 dataerrln("contruct SimpleDateFormat in expectUserDII failed: %s", u_errorName(ec));
1139 UDate date = ref.parse(ctou(datestr), ec);
1140 if (!assertSuccess("parse in expectUserDII", ec)) return;
1141 UDate date_2 = ref.parse(ctou(datestr_2), ec);
1142 if (!assertSuccess("parse in expectUserDII", ec)) return;
1145 ec = U_ZERO_ERROR;
1147 DateIntervalInfo* dtitvinf = new DateIntervalInfo(ec);
1148 dtitvinf->setFallbackIntervalPattern("{0} --- {1}", ec);
1149 dtitvinf->setIntervalPattern(UDAT_YEAR_ABBR_MONTH_DAY, UCAL_MONTH, "yyyy MMM d - MMM y",ec);
1150 if (!assertSuccess("DateIntervalInfo::setIntervalPattern", ec)) return;
1151 dtitvinf->setIntervalPattern(UDAT_YEAR_ABBR_MONTH_DAY, UCAL_HOUR_OF_DAY, "yyyy MMM d HH:mm - HH:mm", ec);
1152 if (!assertSuccess("DateIntervalInfo::setIntervalPattern", ec)) return;
1153 DateIntervalFormat* dtitvfmt = DateIntervalFormat::createInstance(UDAT_YEAR_ABBR_MONTH_DAY, loc, *dtitvinf, ec);
1155 if (!assertSuccess("createInstance(skeleton,dtitvinf) in expectUserDII", ec)) return;
1157 dtitvfmt->format(&dtitv, str.remove(), pos, ec);
1158 if (!assertSuccess("format in expectUserDII", ec)) return;
1280 UErrorCode ec = U_ZERO_ERROR;
1282 SimpleDateFormat ref(data[i++], loc, ec);
1283 if (!assertSuccess("construct SimpleDateFormat", ec)) return;
1301 UDate date = ref.parse(ctou(datestr), ec);
1302 if (!assertSuccess("parse", ec)) return;
1303 UDate date_2 = ref.parse(ctou(datestr_2), ec);
1304 if (!assertSuccess("parse", ec)) return;
1311 DateIntervalFormat* dtitvfmt = DateIntervalFormat::createInstance(oneSkeleton, loc, ec);
1312 if (!assertSuccess("createInstance(skeleton)", ec)) return;
1316 GregorianCalendar* gregCal = new GregorianCalendar(loc, ec);
1317 if (!assertSuccess("GregorianCalendar()", ec)) return;
1321 //dtitvfmt->adoptDateFormat(newOne, ec);
1322 dtitvfmt->setDateFormat(*newOne, ec);
1324 if (!assertSuccess("adoptDateFormat()", ec)) return;
1328 dtitvfmt->format(&dtitv, str.remove(), pos, ec);
1329 if (!assertSuccess("format", ec)) return;
1342 ec = U_ZERO_ERROR;
1343 DateIntervalInfo* dtitvinf = new DateIntervalInfo(ec);
1344 dtitvinf->setFallbackIntervalPattern("{0} --- {1}", ec);
1345 dtitvinf->setIntervalPattern(UDAT_YEAR_ABBR_MONTH_DAY, UCAL_MONTH, "yyyy MMM d - MMM y",ec);
1346 if (!assertSuccess("DateIntervalInfo::setIntervalPattern", ec)) return;
1347 dtitvinf->setIntervalPattern(UDAT_YEAR_ABBR_MONTH_DAY, UCAL_HOUR_OF_DAY, "yyyy MMM d HH:mm - HH:mm", ec);
1348 if (!assertSuccess("DateIntervalInfo::setIntervalPattern", ec)) return;
1349 DateIntervalFormat* dtitvfmt = DateIntervalFormat::createInstance(UDAT_YEAR_ABBR_MONTH_DAY, loc, *dtitvinf, ec);
1351 if (!assertSuccess("createInstance(skeleton,dtitvinf)", ec)) return;
1353 dtitvfmt->format(&dtitv, str.remove(), pos, ec);
1355 if (!assertSuccess("format", ec)) return;
1365 assertTrue("Default calendar for \"th\" is Budhist", ec == U_ILLEGAL_ARGUMENT_ERROR);
1366 ec = U_ZERO_ERROR;