Home
last modified time | relevance | path

Searched refs:dfs (Results 1 – 18 of 18) sorted by relevance

/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/text/
DDecimalFormatSymbolsTest.java39 DecimalFormatSymbols dfs; field in DecimalFormatSymbolsTest
55 DecimalFormatSymbols dfs = new DecimalFormatSymbols(new Locale("en", in test_ConstructorLjava_util_Locale() local
57 assertEquals("Returned incorrect symbols", '%', dfs.getPercent()); in test_ConstructorLjava_util_Locale()
107 assertTrue("Equal objects returned false", dfs.equals(dfs.clone())); in test_equalsLjava_lang_Object()
108 dfs.setDigit('B'); in test_equalsLjava_lang_Object()
109 assertTrue("Un-Equal objects returned true", !dfs in test_equalsLjava_lang_Object()
182 dfs.setDecimalSeparator('*'); in test_getDecimalSeparator()
183 assertEquals("Returned incorrect DecimalSeparator symbol", '*', dfs in test_getDecimalSeparator()
191 dfs.setDigit('*'); in test_getDigit()
192 assertEquals("Returned incorrect Digit symbol", '*', dfs.getDigit()); in test_getDigit()
[all …]
DDateFormatSymbolsTest.java29 private DateFormatSymbols dfs; field in DateFormatSymbolsTest
107 assertTrue("Equal object returned true", dfs.equals(dfs.clone())); in test_equalsLjava_lang_Object()
108 dfs.setLocalPatternChars("KKKKKKKKK"); in test_equalsLjava_lang_Object()
109 assertTrue("Un-Equal objects returned false", !dfs in test_equalsLjava_lang_Object()
119 String[] retVal = dfs.getAmPmStrings(); in test_getAmPmStrings()
133 String[] retVal = dfs.getEras(); in test_getEras()
147 String[] retVal = dfs.getMonths(); in test_getMonths()
162 String[] retVal = dfs.getShortMonths(); in test_getShortMonths()
176 String[] retVal = dfs.getShortWeekdays(); in test_getShortWeekdays()
190 String[] retVal = dfs.getWeekdays(); in test_getWeekdays()
[all …]
DDecimalFormatTest.java46 DecimalFormatSymbols dfs = new DecimalFormatSymbols(); in test_setNan_emptyString() local
47 dfs.setNaN(""); in test_setNan_emptyString()
49 df.setDecimalFormatSymbols(dfs); in test_setNan_emptyString()
850 DecimalFormatSymbols dfs = new DecimalFormatSymbols(Locale.CANADA); in testConstructor_stringAndSymbols() local
851 DecimalFormat format1 = new DecimalFormat("'$'1000.0000", dfs); in testConstructor_stringAndSymbols()
854 format2.setDecimalFormatSymbols(dfs); in testConstructor_stringAndSymbols()
1081 final DecimalFormatSymbols dfs = new DecimalFormatSymbols(Locale.US); in test_formatDouble_scientificNotation() local
1083 DecimalFormat df = new DecimalFormat("00.0#E0", dfs); in test_formatDouble_scientificNotation()
1116 df = new DecimalFormat("#00.0##E0", dfs); in test_formatDouble_scientificNotation()
1155 df = new DecimalFormat("#.0E0", dfs); in test_formatDouble_scientificNotation()
[all …]
DSimpleDateFormatTest.java519 DateFormatSymbols dfs = df.getDateFormatSymbols(); in test_getDateFormatSymbols() local
520 assertTrue("Symbols identical", dfs != df.getDateFormatSymbols()); in test_getDateFormatSymbols()
/libcore/luni/src/test/java/libcore/java/text/
DDecimalFormatSymbolsTest.java40 DecimalFormatSymbols dfs = DecimalFormatSymbols.getInstance(locale); in checkLocaleIsEquivalentToRoot() local
41 assertEquals(DecimalFormatSymbols.getInstance(Locale.ROOT), dfs); in checkLocaleIsEquivalentToRoot() local
64 DecimalFormatSymbols dfs = new DecimalFormatSymbols(Locale.US); in testSetSameCurrency() local
65 dfs.setCurrency(Currency.getInstance("USD")); in testSetSameCurrency()
66 assertEquals("$", dfs.getCurrencySymbol()); in testSetSameCurrency()
67 dfs.setCurrencySymbol("poop"); in testSetSameCurrency()
68 assertEquals("poop", dfs.getCurrencySymbol()); in testSetSameCurrency()
69 dfs.setCurrency(Currency.getInstance("USD")); in testSetSameCurrency()
70 assertEquals("$", dfs.getCurrencySymbol()); in testSetSameCurrency()
76 DecimalFormatSymbols dfs = new DecimalFormatSymbols(Locale.US); in testSetNulInternationalCurrencySymbol() local
[all …]
DOldDecimalFormatSymbolsTest.java27 DecimalFormatSymbols dfs; field in OldDecimalFormatSymbolsTest
30 dfs = new DecimalFormatSymbols(); in setUp()
88 dfs.setMonetaryDecimalSeparator(','); in test_getMonetaryDecimalSeparator()
90 ',', dfs.getMonetaryDecimalSeparator()); in test_getMonetaryDecimalSeparator()
124 dfs.setCurrencySymbol("$"); in test_setCurrencySymbolLjava_lang_String()
125 assertEquals("Returned incorrect CurrencySymbol symbol", "$", dfs.getCurrencySymbol()); in test_setCurrencySymbolLjava_lang_String()
129 dfs.setMonetaryDecimalSeparator('#'); in test_setMonetaryDecimalSeparatorC()
131 '#', dfs.getMonetaryDecimalSeparator()); in test_setMonetaryDecimalSeparatorC()
151 DecimalFormatSymbols dfs = new DecimalFormatSymbols(Locale.FRANCE); in test_DecimalFormatSymbols_France() local
152 assertEquals("EUR", dfs.getCurrency().getCurrencyCode()); in test_DecimalFormatSymbols_France()
[all …]
DDateFormatSymbolsTest.java42 DateFormatSymbols dfs = DateFormatSymbols.getInstance(locale); in assertLocaleIsEquivalentToRoot() local
43 assertEquals(DateFormatSymbols.getInstance(Locale.ROOT), dfs); in assertLocaleIsEquivalentToRoot() local
88 private String formatDate(Locale l, String fmt, DateFormatSymbols dfs) { in formatDate() argument
90 sdf.setDateFormatSymbols(dfs); in formatDate()
175 DateFormatSymbols dfs = DateFormatSymbols.getInstance(); in test_setZoneStrings_checks_dimensions() local
176 String[][] zoneStrings = dfs.getZoneStrings(); in test_setZoneStrings_checks_dimensions()
179 dfs.setZoneStrings(zoneStrings); in test_setZoneStrings_checks_dimensions()
187 DateFormatSymbols dfs = DateFormatSymbols.getInstance(); in test_zoneStrings_are_lazy() local
189 assertFalse("Newly created DFS should have no zoneStrings", hasZoneStringsFieldValue(dfs)); in test_zoneStrings_are_lazy()
190 dfs.hashCode(); in test_zoneStrings_are_lazy()
[all …]
DDecimalFormatTest.java36 DecimalFormatSymbols dfs = df.getDecimalFormatSymbols(); in test_exponentSeparator() local
37 dfs.setExponentSeparator("-useless-api-"); in test_exponentSeparator()
38 df.setDecimalFormatSymbols(dfs); in test_exponentSeparator()
311 DecimalFormatSymbols dfs = new DecimalFormatSymbols(locale); in testCurrencySymbolSpacing() local
312 String formattedZero = new DecimalFormat("0", dfs).format(0); in testCurrencySymbolSpacing()
314 assertCurrencyFormat("USD" + formattedZero, "\u00a4\u00a40", dfs, currency, locale); in testCurrencySymbolSpacing()
315 assertCurrencyFormat(formattedZero + "USD", "0\u00a4\u00a4", dfs, currency, locale); in testCurrencySymbolSpacing()
316 assertCurrencyFormat(currency.getSymbol(locale) + formattedZero, "\u00a40", dfs, in testCurrencySymbolSpacing() local
318 assertCurrencyFormat(formattedZero + currency.getSymbol(locale), "0\u00a4", dfs, in testCurrencySymbolSpacing()
324 DecimalFormatSymbols dfs, in assertCurrencyFormat() argument
[all …]
DNumberFormatTest.java182 DecimalFormatSymbols dfs = ((DecimalFormat) nf).getDecimalFormatSymbols(); in test_customCurrencySymbol() local
183 dfs.setCurrencySymbol("SPECIAL"); in test_customCurrencySymbol()
184 ((DecimalFormat) nf).setDecimalFormatSymbols(dfs); in test_customCurrencySymbol()
192 dfs.setCurrencySymbol("NEW"); in test_customCurrencySymbol()
193 ((DecimalFormat) nf).setDecimalFormatSymbols(dfs); in test_customCurrencySymbol()
DSimpleDateFormatTest.java696 DateFormatSymbols dfs = dateFormat.getDateFormatSymbols(); in testTimeZoneParsingErrorIndexWithZoneStrings() local
697 dfs.setZoneStrings(dfs.getZoneStrings()); in testTimeZoneParsingErrorIndexWithZoneStrings()
698 dateFormat.setDateFormatSymbols(dfs); in testTimeZoneParsingErrorIndexWithZoneStrings()
/libcore/luni/src/main/java/libcore/icu/
DLocaleData.java349 DateFormatSymbols dfs = new DateFormatSymbols(GregorianCalendar.class, locale); in initializeDateFormatData() local
351 longMonthNames = dfs.getMonths(DateFormatSymbols.FORMAT, DateFormatSymbols.WIDE); in initializeDateFormatData()
352 shortMonthNames = dfs.getMonths(DateFormatSymbols.FORMAT, DateFormatSymbols.ABBREVIATED); in initializeDateFormatData()
353 tinyMonthNames = dfs.getMonths(DateFormatSymbols.FORMAT, DateFormatSymbols.NARROW); in initializeDateFormatData()
354 longWeekdayNames = dfs.getWeekdays(DateFormatSymbols.FORMAT, DateFormatSymbols.WIDE); in initializeDateFormatData()
355 shortWeekdayNames = dfs in initializeDateFormatData()
357 tinyWeekdayNames = dfs.getWeekdays(DateFormatSymbols.FORMAT, DateFormatSymbols.NARROW); in initializeDateFormatData()
359 longStandAloneMonthNames = dfs in initializeDateFormatData()
361 shortStandAloneMonthNames = dfs in initializeDateFormatData()
363 tinyStandAloneMonthNames = dfs in initializeDateFormatData()
[all …]
/libcore/ojluni/src/main/java/java/text/
DDecimalFormatSymbols.java823 android.icu.text.DecimalFormatSymbols dfs) { in fromIcuInstance() argument
824 DecimalFormatSymbols result = new DecimalFormatSymbols(dfs.getLocale()); in fromIcuInstance()
825 result.setZeroDigit(dfs.getZeroDigit()); in fromIcuInstance()
826 result.setDigit(dfs.getDigit()); in fromIcuInstance()
827 result.setDecimalSeparator(dfs.getDecimalSeparator()); in fromIcuInstance()
828 result.setGroupingSeparator(dfs.getGroupingSeparator()); in fromIcuInstance()
829 result.setPatternSeparator(dfs.getPatternSeparator()); in fromIcuInstance()
830 result.setPercent(dfs.getPercent()); in fromIcuInstance()
831 result.setPerMill(dfs.getPerMill()); in fromIcuInstance()
832 result.setMonetaryDecimalSeparator(dfs.getMonetaryDecimalSeparator()); in fromIcuInstance()
[all …]
DDateFormatSymbols.java433 DateFormatSymbols dfs; in getCachedInstance() local
434 if (ref == null || (dfs = ref.get()) == null) { in getCachedInstance()
435 dfs = new DateFormatSymbols(locale); in getCachedInstance()
436 ref = new SoftReference<>(dfs); in getCachedInstance()
441 dfs = y; in getCachedInstance()
448 return dfs; in getCachedInstance()
826 DateFormatSymbols dfs; in initializeData() local
828 if (ref != null && (dfs = ref.get()) != null) { in initializeData()
829 copyMembers(dfs, this); in initializeData()
/libcore/benchmarks/src/benchmarks/regression/
DExpensiveObjectsBenchmark.java75 DateFormatSymbols dfs = new DateFormatSymbols(Locale.US); in timeClonedDateFormatSymbols() local
77 dfs.clone(); in timeClonedDateFormatSymbols()
88 DecimalFormatSymbols dfs = new DecimalFormatSymbols(Locale.US); in timeClonedDecimalFormatSymbols() local
90 dfs.clone(); in timeClonedDecimalFormatSymbols()
/libcore/luni/src/test/native/
Dlibcore_libcore_icu_LocaleDataTest.cpp184 icu::DecimalFormatSymbols dfs(locale, status); in setDecimalFormatSymbolsData() local
186 …setCharField(env, obj, "decimalSeparator", dfs.getSymbol(icu::DecimalFormatSymbols::kDecimalSepara… in setDecimalFormatSymbolsData()
187 …setCharField(env, obj, "groupingSeparator", dfs.getSymbol(icu::DecimalFormatSymbols::kGroupingSepa… in setDecimalFormatSymbolsData()
188 …setCharField(env, obj, "patternSeparator", dfs.getSymbol(icu::DecimalFormatSymbols::kPatternSepara… in setDecimalFormatSymbolsData()
189 setStringField(env, obj, "percent", dfs.getSymbol(icu::DecimalFormatSymbols::kPercentSymbol)); in setDecimalFormatSymbolsData()
190 setStringField(env, obj, "perMill", dfs.getSymbol(icu::DecimalFormatSymbols::kPerMillSymbol)); in setDecimalFormatSymbolsData()
191 …setCharField(env, obj, "monetarySeparator", dfs.getSymbol(icu::DecimalFormatSymbols::kMonetarySepa… in setDecimalFormatSymbolsData()
192 …setStringField(env, obj, "minusSign", dfs.getSymbol(icu::DecimalFormatSymbols:: kMinusSignSymbol)); in setDecimalFormatSymbolsData()
193 …setStringField(env, obj, "exponentSeparator", dfs.getSymbol(icu::DecimalFormatSymbols::kExponentia… in setDecimalFormatSymbolsData()
194 setStringField(env, obj, "infinity", dfs.getSymbol(icu::DecimalFormatSymbols::kInfinitySymbol)); in setDecimalFormatSymbolsData()
[all …]
/libcore/ojluni/src/main/java/java/util/
DFormatter.java2287 DecimalFormatSymbols dfs = DecimalFormatSymbols.getInstance(l); in getZero() local
2288 return dfs.getZeroDigit(); in getZero()
3999 DateFormatSymbols dfs = DateFormatSymbols.getInstance(l);
4000 ampm = dfs.getAmPmStrings();
4045 DateFormatSymbols dfs = DateFormatSymbols.getInstance(lt);
4047 sb.append(dfs.getWeekdays()[i]);
4049 sb.append(dfs.getShortWeekdays()[i]);
4057 DateFormatSymbols dfs = DateFormatSymbols.getInstance(lt);
4059 sb.append(dfs.getMonths()[i]);
4061 sb.append(dfs.getShortMonths()[i]);
[all …]
DScanner.java1204 DecimalFormatSymbols dfs = DecimalFormatSymbols.getInstance(locale); in useLocale() local
1208 groupSeparator = "\\" + dfs.getGroupingSeparator(); in useLocale()
1209 decimalSeparator = "\\" + dfs.getDecimalSeparator(); in useLocale()
1213 nanString = "\\Q" + dfs.getNaN() + "\\E"; in useLocale()
1214 infinityString = "\\Q" + dfs.getInfinity() + "\\E"; in useLocale()
/libcore/ojluni/annotations/hiddenapi/java/text/
DDecimalFormatSymbols.java229 android.icu.text.DecimalFormatSymbols dfs) { in fromIcuInstance() argument