Lines Matching refs:MessageFormat

188     LocalPointer<MessageFormat> fmt(new MessageFormat(pattern, status));
190 dataerrln("MessageFormat pattern creation failed. - %s", u_errorName(status));
195 errln("MessageFormat::toPattern() failed.");
302 LocalPointer<MessageFormat> form;
305 form.adoptInstead(new MessageFormat(testCases[i], Locale::getUS(), success));
307 dataerrln("MessageFormat creation failed.#1 - %s", u_errorName(success));
308 logln(((UnicodeString)"MessageFormat for ") + testCases[i] + " creation failed.\n");
331 dataerrln("MessageFormat failed test #3 - %s", u_errorName(success));
356 errln("MessageFormat failed test #5");
357 logln(UnicodeString("MessageFormat failed test #5 with error code ")+(int32_t)success);
370 errln("MessageFormat failed test #6");
377 MessageFormat *form = 0;
380 form = new MessageFormat("There are {0} files on {1}", success);
407 result = MessageFormat::format(
443 result = MessageFormat::format(
475 MessageFormat* form = new MessageFormat(
509 MessageFormat* form = new MessageFormat("The disk \"{1}\" contains {0}.", err);
555 MessageFormat* mfNum = new MessageFormat(t1, Locale("fr"), err);
566 MessageFormat* mfAlpha = new MessageFormat(t2, Locale("fr"), err);
589 MessageFormat* mfNum2 = new MessageFormat(t3, Locale("uk"), err);
593 MessageFormat* mfAlpha2 = new MessageFormat(t4, Locale("uk"), err);
617 MessageFormat* msgFmt = new MessageFormat(t5, Locale("fr"), err);
639 MessageFormat msgFmt(UNICODE_STRING_SIMPLE(
644 errln("MessageFormat constructor failed - %s\n", u_errorName(errorCode));
651 "MessageFormat with apostrophes in plural/select arguments failed:\n");
654 void TestMessageFormat::internalFormat(MessageFormat* msgFmt ,
675 MessageFormat* TestMessageFormat::internalCreate(
678 //Create the MessageFormat with simple SelectFormat
679 LocalPointer<MessageFormat> msgFmt(new MessageFormat(pattern, locale, status));
697 //Create the MessageFormat with simple French pattern
698 MessageFormat* msgFmt1 = internalCreate(t1.unescape(), Locale("fr"),err,(char*)"From TestMessageFormat::TestSelectFormat create t1");
719 //Create the MessageFormat with Quoted French pattern
720 MessageFormat* msgFmt2 = internalCreate(t2.unescape(), Locale("fr"),err,(char*)"From TestMessageFormat::TestSelectFormat create t2");
741 //Create the MessageFormat with English pattern
742 MessageFormat* msgFmt3 = internalCreate(t3, Locale("en"),err,(char*)"From TestMessageFormat::TestSelectFormat create t3");
764 //Create the MessageFormat with Select Format with embedded number format (nested pattern)
765 MessageFormat* msgFmt4 = internalCreate(t4.unescape(), Locale("fr"),err,(char*)"From TestMessageFormat::TestSelectFormat create t4");
786 //Create the MessageFormat with Plural format with embedded select format(nested pattern)
787 MessageFormat* msgFmt5 = internalCreate(t5.unescape(), Locale("fr"),err,(char*)"From TestMessageFormat::TestSelectFormat create t5");
788 // with no data the above should fail but it seems to construct an invalid MessageFormat with no reported error. See #13079
811 //Create the MessageFormat with Select, plural, and number formats heavily nested
812 LocalPointer<MessageFormat> msgFmt6(
864 MessageFormat *x = new MessageFormat("There are {0} files on {1}", success);
865 MessageFormat *z = new MessageFormat("There are {0} files on {1} created", success);
866 MessageFormat *y = 0;
867 y = new MessageFormat(*x);
894 MessageFormat *x = new MessageFormat("There are {0} files on {1}", success);
895 MessageFormat *z = new MessageFormat("There are {0} files on {1} created", success);
896 MessageFormat *y = new MessageFormat("There are {0} files on {1} created", success);
923 MessageFormat *x = new MessageFormat("There are {0} files on {1}", success);
924 MessageFormat *z = new MessageFormat("There are {0} files on {1} created", success);
925 MessageFormat *y = 0;
952 MessageFormat x("There are {0} files on {1}", success);
953 MessageFormat y("There are {0} files on {1}", success);
964 MessageFormat x("There are {0} files on {1}", success);
965 MessageFormat y(x);
1008 MessageFormat msg( formatStr, err);
1083 MessageFormat msg( formatStr, err);
1126 MessageFormat msg( msgFormatString, err);
1204 MessageFormat msg( formatStr, err);
1205 MessageFormat msgCmp( formatStr, err);
1207 dataerrln("Unable to instantiate MessageFormat - %s", u_errorName(err));
1420 MessageFormat* fmt1 = new MessageFormat( formatStr, status );
1421 MessageFormat* fmt2 = NULL;
1422 MessageFormat* fmt3 = NULL;
1423 MessageFormat* fmt4 = NULL;
1430 fmt2 = new MessageFormat( *fmt1 );
1467 * Verify that MessageFormat accommodates more than 10 arguments and
1479 MessageFormat msg(pattern, ec);
1553 MessageFormat* fmt = new MessageFormat(formats[i], locale, ec);
1641 MessageFormat compMsg("", Locale::getUS(), ec);
1647 MessageFormat icuMsg("", Locale::getUS(), ec);
1656 assertEquals("incompatible ICU MessageFormat compatibility-apostrophe behavior",
1659 assertEquals("unexpected ICU MessageFormat double-apostrophe-optional behavior",
1673 assertEquals("incompatible ICU MessageFormat compatibility-apostrophe behavior",
1676 assertEquals("unexpected ICU MessageFormat double-apostrophe-optional behavior",
1717 UnicodeString result = MessageFormat::autoQuoteApostrophe(patterns[i], status);
1736 MessageFormat *msgfmt = new MessageFormat(testformat, Locale("fr"), status);
1738 dataerrln("FAIL: Unable to create MessageFormat.: %s", u_errorName(status));
1780 msgfmt = new MessageFormat("'", status);
1782 errln("FAIL: Unable to create MessageFormat.");
1790 // on a MessageFormat without named arguments.
1807 MessageFormat msgfmt("Hello, {alice,number} {oops,date,full} {zip,spellout} World.", Locale::getRoot(), errorCode);
1808 if(errorCode.errDataIfFailureAndReset("MessageFormat() failed")) {
1853 MessageFormat m("a { 0 , number , '#,#'#.0 } z", Locale::getEnglish(), errorCode);
1854 if (errorCode.errDataIfFailureAndReset("Unable to instantiate MessageFormat")) {
1875 MessageFormat m(
1879 if (errorCode.errDataIfFailureAndReset("Unable to instantiate MessageFormat")) {
1906 MessageFormat m(
1921 MessageFormat m0(
1935 MessageFormat m1(
1954 MessageFormat m2(
1977 MessageFormat mf1("{0,select,a{A}ab{AB}abc{ABC}other{?}}", Locale::getEnglish(), errorCode);
1989 MessageFormat mf2("{a} {aa} {aaa}", Locale::getEnglish(), errorCode);
1997 MessageFormat mf3("{aa} {aaa}", Locale::getEnglish(), errorCode);
2024 MessageFormat msgf(cas.messagePattern, cas.localeName, status);
2040 MessageFormat msgf(messagePattern, localeName, status);