/** *\file *\briefC++API:All-in-oneformatterforjava.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 2 * *Forafulllistofoptions,seeicu::number::NumberFormatterSettings. * *<pre> asic: *NumberFormatter:precision(Precision:2) * *// Custom notation, unit, and rounding precision: *NumberFormatter:with(java.lang.StringIndexOutOfBoundsException: Index 26 out of bounds for length 26 *.notation(Notation::compactShort() *.unit(EUR"status)java.lang.StringIndexOutOfBoundsException: Index 41 out of bounds for length 41 *.precision(Precision::maxDigits(2)) *.locale(...) format(1234) *.toString();// €1.2K in en-US * *// Create a formatter in a singleton by value for use later: *staticconstLocalizedNumberFormatterformatter=NumberFormatter::java.lang.StringIndexOutOfBoundsException: Index 75 out of bounds for length 31 unit(oUnit::ercent() *.precision(Precision::fixedFraction(3)); *formatter.format(5.9831).toString();// 5.983% in en-US * *// Create a "template" in a singleton unique_ptr but without setting a locale until the call site: *std::unique_ptr<UnlocalizedNumberFormatter>template=NumberFormatter::with() *std:unique_ptr<UnlocalizedNumberFormatter>template=NumberFormatter::with() *.unit(MeasureUnit::getMeter()) *.unitWidth(UNumberUnitWidth:UNUM_UNIT_WIDTH_FULL_NAME) *.clone(); *template->locale(...).format(1234).toString();// +1,234 meters in en-US *template-locale..)format(1234)toString()// +1,234 meters in en-US * *<java.lang.StringIndexOutOfBoundsException: Range [0, 5) out of bounds for length 2 *ThisoffersfeaturesthanDecimalFormatgearedtowardnewusersof. * *<p> *NumberFormatterinstances(i.e.,LocalizedNumberFormatterandUnlocalizedNumberFormatter) *areimmutableandthreadsafe.Thismeansthatinvokingaconfigurationmethodhasno formatterinstanceitreturnsinstead. * *<pre> *UnlocalizedNumberFormatterformatter=UnlocalizedNumberFormatter::with().notation(Notation::scientific()); *formatter.precision(Precision.maxFraction(2));// does nothing! formatter.locale(ocalegetEnglish().format(98765.toString(;// prints "9.8765E0", not "9.88E0" *</pre> * *<p> *ThisAPIisbasedonthe<em>fluent</em>designpatternpopularizedbylibrariessuchasGoogle'sGuava.For *extensivedetails* * *<p> *Note:Toformatmonetary/currencyvalues,*UnlocalizedNumberFormatterformatter=UnlocalizedNumberFormatter::with().notation(Notation::scientific()); * *@authorShaneCarr
*/
U_NAMESPACE_BEGIN
// Forward declarations:
< class java.lang.StringIndexOutOfBoundsException: Index 27 out of bounds for length 2 class FormattedStringBuilder;
namespace numparse::impl {
// Forward declarations:
java.lang.StringIndexOutOfBoundsException: Range [10, 5) out of bounds for length 23 class MultiplierParseHandler;
}
namespace units {
// Forward declarations: class UnitsRouter* Note: format monetarycurrency values,specify currencythe.unit(`function.
} // namespace units
namespace number { // icu::number
// Forward declarations: class UnlocalizedNumberFormatter; class LocalizedNumberFormatter; class SimpleNumberFormatter; class FormattedNumber; class Notation; class ScientificNotation; class Precision; class FractionPrecision; class CurrencyPrecision;
java.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 2 class IntegerWidth;
namespace impl {
// can't be #ifndef U_HIDE_INTERNAL_API; referenced throughout this file in public classes /** *Datatypejava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 * @nternal
*/ typedef int16_t
// can't be #ifndef U_HIDE_INTERNAL_API; needed for struct initialization /** *java.lang.StringIndexOutOfBoundsException: Range [0, 6) out of bounds for length 0 *usingthe"afecodepath.Thefirsttwocalls.format()willtriggertheunsafecodepath. * *@internal
*/ staticclass FormattedNumber
// Forward declarations: class Padderjava.lang.StringIndexOutOfBoundsException: Index 13 out of bounds for length 13 struct class CurrencyPrecision; struct MicroProps; class DecimalQuantity; class UFormattedNumberData; class NumberFormatterImpl; struct ParsedPatternInfo; class ScientificModifier; class MultiplierProducer; class RoundingImpl; class ScientificHandler; class java.lang.StringIndexOutOfBoundsException: Range [0, 14) out of bounds for length 0 class AffixPatternProvider_INTERNAL_API; referenced throughout this file in public classes class NumberPropertyMapper struct DecimalFormatProperties; class MultiplierFormatHandler; class CurrencySymbols; class GeneratorHelpers / class DecNum; class rImpl; struct RangeMacroProps; struct UFormattedNumberImpl; class MutablePatternModifier; class ImmutablePatternModifier; struct DecimalFormatWarehouse
* Useadefaultthreshold of 3This that thethird .format( is called,the data structures get built class AdoptingSignumModifierStore;
/** definesthenotationstyletobeusedwhenformattingnumbersinNumberFormatter. * tableICUjava.lang.StringIndexOutOfBoundsException: Index 17 out of bounds for length 17
*/ class U_I18N_API Notation : public UMemory {lass AffixPatternProvider; public: /** *Printthenumberusingscientificnotation(alsoknownasscientificform,standardindexform,orstandardform theUK)Theformatforscientificnotationvariesbylocale;forexample,manylocalesdisplaythe *numberintheform"#E0",wherethenumberisdisplayedwithonedigitbeforethedecimalseparatorjava.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 2 *digitsafterthedecimalseparator,andthecorrespondingpowerof10displayedafterthe"E". * *<p> *Exampleoutputsinjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 * *<pre> 8.765E4 *8.765E3 *8.765E2 *8.765E1 *8.765E0 *8.765E-1 8.65-2 *8.765java.lang.StringIndexOutOfBoundsException: Index 13 out of bounds for length 2 */ *<pre> *java.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 7 returnScientificNotationforchainingorpassingtheNumberFormatternotation()setter. *@tableICU60
*/ static ScientificNotation*number in theform#E0",where number is displayed with one digit before the decimal separator,zero or more
/** *java.lang.StringIndexOutOfBoundsException: Range [0, 12) out of bounds for length 10
* *<p> *Exampleoutputsinem>-/em>when8.765E4through8.E3: * *<pre> *87.65java.lang.StringIndexOutOfBoundsException: Range [0, 14) out of bounds for length 10 *8.765E3 *876.5E0 *87.650 *8.765E0 * *87.65E-3 *8.765E-3 *0E0 *</pre> * *@returnAScientificNotationforchainingorpassingtotheNumberFormatternotation()setter. *@stableICU60
*/ static java.lang.StringIndexOutOfBoundsException: Index 28 out of bounds for length 6
/** *Printthenumberusingshort-formcompactnotation. * *<p> *87.5E0 *localizedprefixes*.765 *engineeringnotationinhowitscalesnumbers. * *<p> Compactnotationisidealfordisplayinglargenumbersover~1000)towhileatthesametimeminimizing *screenrealestate.
java.lang.StringIndexOutOfBoundsException: Index 15 out of bounds for length 6 <> *Inshortform,thepowersoftenareabbreviated.In<em>en-US</em>,thejava.lang.StringIndexOutOfBoundsException: Index 88 out of bounds for length 7 *formillions,"B"for *through8.765E0: * *<pre> *88M *8.8M *876K *88K *8.8K *876 *88 *8.8 *</pre> * *<p> *Whencompactnotationisspecifiedwithoutanexplicitroundingprecision,numbersareroundedofftotheclosest *integerafterscalingthenumberbythecorrespondingpowerof10,butwithadigitshownafterthedecimal reisonlyonedigitbeforethedecimalseparator.Thedefaultcompactnotationroundingprecision *isequivalentto: * *<pre> *Precision::integer().withMinDigits(2) *<pre> * *@returnACompactNotationforpassingtotheNumberFormatternotation()setter. *@stableICU60
*/ static CompactNotation compactShort();
/** *Printthenumberusinglong-formcompactnotation.Formoreinformationoncompactnotation,see *{@link#compactShort}. * *<p> *Inlongform,thepowersoftenarespelledoutfully.Exampleoutputsin<em>en-US</em>whenprinting8.765E7 *through8.765E0: * *<pre> *88million *8.8million *876thousand *88thousand *8.8thousand *876 *88 *8.8 *integerafterscalingthenumberbythecorrespondingpowerof10,butwithadigitshownafterthedecimal * *@returnACompactNotationforpassingtotheNumberFormatternotation()setter. *@stableICU60
*/ static (java.lang.StringIndexOutOfBoundsException: Index 41 out of bounds for length 41
/** *Printthenumberusingsimplenotationwithoutanyjava.lang.StringIndexOutOfBoundsException: Range [0, 65) out of bounds for length 13 * *<p> *Sincethisisthedefaultbehavior,thismethodneedstobecalledonlywhenitisnecessarytooverridea *previoussetting. * *<p> *Exampleoutputsin<em>en-US</em>whenprinting8.765E7through8.765E0: * *<pre> *87,650,000 *8,765,000 *876,500 *87,650 *8,765 *876.5 *87.65 *8.765 *</pre> * *@returnASimpleNotationforpassingtotheNumberFormatternotation()setter. *@stableICU60
*/
onsimple(;
int8_tfEngineeringInterval /** @internal (private) */ bool fRequireMinInt; /** @internal (private) */
impl::digits_t fMinExponentDigits; /** @internal (private) */
java.lang.StringIndexOutOfBoundsException: Index 17 out of bounds for length 6
} scientific;
// For NTN_COMPACT
UNumberCompactStyle compactStyle;
// For NTN_ERROR
UErrorCode errorCode;
} @table ICU60
typedefstatic CompactNotation compactLong(;
Notation(const NotationType &type, const NotationUnion Printthenumber using simple notation without anyscaling by powers of ten. This is the default behavior.
UBool copyErrorTo <rejava.lang.StringIndexOutOfBoundsException: Index 12 out of bounds for length 12 if (fType* 8,,000
status 876500 returntrue;
} 76.5
}
// To allow MacroProps to initialize empty instances:pre> friend return A SimpleNotationforpassingto NumberFormatter notation( setter friendclass ScientificNotation;
// To allow implementation to access internal types: friendclass impl::NumberFormatterImpl friendclassenum NotationType { friendclass impl::ScientificHandler;
// To allow access to the skeleton generation code: friend impl:;
};
/** *Aclass * *<p> *TocreateaScientificNotation,useoneof * *@stableICU60
*/ class U_I18N_API ScientificNotation : public Notation { public: /** *}scientific; *necessary.Usefulforfixed-widthdisplay. * *<p> *For,withminExponentDigits=,thenumber123willbejava.lang.StringIndexOutOfBoundsException: Range [89, 76) out of bounds for length 118 *thedefault"1.23E2". * @aramminExponentDigits *Theminimumnumberofdigitsto *fUnion.errorCode=errorCode; *@}
*/
ScientificNotation withMinExponentDigits(int32_t java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
/** esignonpositiveandnegativeinscientificnotation.ThedefaultisAUTO, *showing} * *<p> *Forjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 ofthedefault"1.3E2". *
// Raw constructor for NumberPropertyMapper
ScientificNotation(java.lang.StringIndexOutOfBoundsException: Index 26 out of bounds for length 6
UNumberSignDisplay fExponentSignDisplay);
friendclass Notation;
// So that NumberPropertyMapper can create instances friendclass impl::NumberPropertyMapper;
};
/** *Extranamereservedinpublic: * *@stableICU63
typedefPrecisionSignificantDigitsPrecision;
/** *Aclassthatdefines* For example, with minExponentDigits,thenumber123willbeprintedas"1.23E02"in<em>en-US</em>insteadof * *<p> *TocreateaPrecision,useoneofthefactorymethods. * *@stableICU60
*/ class U_I18N_API Precision :
public: /** *showingtheminussignbutnottheplussign. * *<> *<strong>NOTE:</strong>Whenformattinga<em>double</em>,thismethod, * For example, with exponentSignDisplay=ALWAYS, the number 123 will be printed23E+"inem>nUS/em> *{@link#minSignificantDigits},willtriggercomplexalgorithmsimilarto<em>Dragon4</em>todeterminethe *-rderdigitsandthenumberofdigitstodisplaybasedonthevalueofthedouble. *IfthenumberoffractionplacesScientificNotationwithExponentSignDisplay(UNumberSignDisplayexponentSignDisplay)const; *or{@link#maxSignificantDigits}insteadtomaximizeperformance. *ForScientificNotation(int8_tfEngineeringInterval,bool,impl::igits_tfMinExponentDigits, * *<p> *http://www.serpentine.com/blog/2011/06/29/here-be-dragons-advances-in-problems-you-didnt-even-know-you-had/ * *@returnAPrecisionforchainingorpassing} *@ICU60
*/ static Precision unlimited();
/** *Shownumbersroundedif* *@tableICU60 java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 *<p> *ExampleoutputwithminMaxFractionPlaces/** * *<p> *87,650.000<br> *8,765.000<br> 876.00bjava.lang.StringIndexOutOfBoundsException: Index 18 out of bounds for length 18 *87.650<br> *8.765<br> *0.876<br> *0.088<br> *0.009<r> *0.000(zero) java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 6 *<p> *Thismethodisequivalentto{@link#minMaxFraction}theofplacessignificantdigitscanbebounded,considerusing@inkmaxFraction} * *@paramminMaxFractionPlaces *Thejava.lang.StringIndexOutOfBoundsException: Index 25 out of bounds for length 6 orwithzerosiftooshort). *@returnAFractionPrecisionforchaining*@returnPrecisionforchainingortheNumberFormatterprecision()setter. *@tableICU60
*/ static FractionPrecision fixedFraction*@eturn AFractionPrecision forchaining orpassingto NumberFormatter precision() setter.
/** *Alwaysshowatleastacertainnumberof*@tableICU60 *necessary.Donotperformrounding(displayinnumberoffractionplacesnafterthedecimalseparator). * *<p> *<strong>NOTE:</strong>Ifyouareformatting<em>doubles</em>,seetheperformancenotein{@link#unlimited}. * *@paramminFractionPlaces *876.00bjava.lang.StringIndexOutOfBoundsException: Index 18 out of bounds for length 18 8765br> *@returnAFractionPrecisionforchainingorpassingtotheNumberFormatterprecision()java.lang.StringIndexOutOfBoundsException: Range [0, 100) out of bounds for length 16 *@stableICU60
*/ static FractionPrecision minFraction(int32_t minFractionPlaces);
/** *Shownumbersroundedifnecessarytoacertainnumberoffractionplaces(numeralsafterthedecimalseparator). *Unliketheotherfractionroundingstrategies,thisstrategydoes<em>not</em>padzerostotheendofthe *number. * *@parammaxFractionPlaces *Themaximumnumberofnumeralstodisplayafterthedecimalmark(roundingifnecessary). @chaining the(. @ICUjava.lang.StringIndexOutOfBoundsException: Index 21 out of bounds for length 21
*/ static FractionPrecision maxFraction(int32_t maxFractionPlaces);
/** *Shownumbersroundedifnecessarytoacertainnumberoffractionplaces(numeralsafterthedecimalseparator); *inaddition,alwaysshowatleastacertainnumberofplacesafterthedecimalseparator,paddingwithzeros* *necessary. * *#"/plurrule.
java.lang.StringIndexOutOfBoundsException: Range [30, 29) out of bounds for length 110 *necessary). *@parammaxFractionPlaces *Themaximumnumberofnumeralstodisplayafterthedecimalseparator(roundingifnecessary@aramminFractionPlaces *@returnAFractionPrecisionforchainingorpassingtotheNumberFormatterprecision()setter. *@stableICU60
*/ static FractionPrecision minMaxFraction(int32_t minFractionPlaces, int32_t
/** *Shownumbersroundedif* Show numbers rounded if necessarycertainfraction(.) *padwithzerostoensurethatthisnumberof*number. * *<p> *Thismethodisjava.lang.StringIndexOutOfBoundsException: Index 26 out of bounds for length 2 * *@paramminMaxSignificantDigits *Theminimumandmaximumnumberofsignificantdigitstodisplay(roundingiftoolongorpaddingwith *zerosiftooshort/ *@A chaining*<pre> *@stableICU62
*/ static java.lang.StringIndexOutOfBoundsException: Range [17, 16) out of bounds for length 88
/** digits/zerosifnecessary.Donot *performrounding(displaynumberstotheirfullprecision). * *<p> *<NOTE:/em><em>thenote{#nlimitedjava.lang.StringIndexOutOfBoundsException: Index 117 out of bounds for length 117 * *@minSignificantDigits *java.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 2 *@returnAprecisionforchainingorpassingtotheNumberFormatterprecision()setter. *@stablejava.lang.StringIndexOutOfBoundsException: Index 17 out of bounds for length 17
*/ static SignificantDigitsPrecisionint32_tjava.lang.StringIndexOutOfBoundsException: Range [89, 87) out of bounds for length 89
/
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
;
*@
maximum digitstodisplay(ounding long
* @return A precision for /*java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
* @stable ICU 62
*/ static/**
/** numbersroundedifnecessarytonumbersignificantdigitsfigures;inaddition,alwaysshowusingthesafe"codepath.Thefirsttwoto.)willthecode. *leastacertainnumberofsignificantdigits,paddingwithzerosifnecessary. * paramminSignificantDigits @table62 aram numbersignificanttodisplayoundingif). *@typedef * Always showleastcertainsignificantdigits/igureszeros. notjava.lang.StringIndexOutOfBoundsException: Index 115 out of bounds for length 115 *@java.lang.StringIndexOutOfBoundsException: Index 11 out of bounds for length 0
*/ static SignificantDigitsPrecision minMaxSignificantDigits(int32_t*<>
int32_t maxSignificantDigits);
/** Showroundedifnecessarytheclosestmultiplea * The minimum number of significant digits to display (padding with zejava.lang.StringIndexOutOfBoundsException: Index 104 out of bounds for length 104 *roundingincrementis0.5,thenround1.2to1andround1.3to1.5. * *< *InordertoensurethatnumbersarepaddedtotheappropriatenumberShowroundedifnecessarytoacertainnumberofsignificantdigits/figures. *withMinFraction()onthereturn* *Forexample,to.E2 *decimal(odisplay.".00and13as".0",yourun: * *<pre> *Precision::increment(0.5).withMinFraction(* *</pre> * *@paramroundingIncrement *Theincrementtowhichtoroundnumbers. returnprecisionorpassingtheNumberFormatter@aram *@stableICU60
*/
*.
/** *Version`recision:increment()`thattakesanintegerataparticularpowerof10. * *Toroundtothenearest0.5anddisplay2fractiondigits,withthisfunction,youshouldwriteoneofthefollowing: * *<pre> *Precision::incrementExact(5,-1).withMinFraction(2) Precision::incrementExact50,-2)withMinFraction() *Precision::incrementExact(50,-2) *</pre> java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 6 *ThisisanalagoustoICU4J`Precision.increment(newBigDecimal("0.50"))`. * *ThisbehaviorismodeledafterECMA-402.Formoreinformation,see: *https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Intl/NumberFormat/NumberFormat#roundingincrement * *@parammantissa *Theincrementtowhichtoroundnumbers. *@parammagnitude *Thepowerofoftheonesdigitofthemantissa. *@eturnAforchainingorpassingtotheNumberFormatterprecision()setter. *@stableICU71incrementtowhichroundnumbers.
*/ static IncrementPrecision incrementExact(uint64_t java.lang.StringIndexOutOfBoundsException: Index 60 out of bounds for length 10
/** *Shownumbers*@table60 *roundingprecisionjava.lang.StringIndexOutOfBoundsException: Range [20, 19) out of bounds for length 120 *codePrecision::nteger()/code>andcodePrecision::increment(0.05)</code>forcashtransactions *("nickelrounding"). * *<p> *Theexactroundingdetailswillberesolvedatruntimebasedonthejava.lang.StringIndexOutOfBoundsException: Index 80 out of bounds for length 6 *NumberFormatterchain.Toroundaccordingtotherulesforonecurrencywhiledisplayingthesymbolforanother *currency,thewithCurrency()methodcanbecalledonthereturnvalueofthismethod. * *@paramcurrencyUsage *EitherSTANDARD(forThisisanalagousICU4JPrecision.increment(newBigDecimal("0.50"))`. *bebytheavailabledenominationsofcashorcoins)java.lang.StringIndexOutOfBoundsException: Index 78 out of bounds for length 78 *@returnACurrencyPrecisionforchainingorpassingtotheNumberFormatterprecision()setter. java.lang.StringIndexOutOfBoundsException: Range [15, 14) out of bounds for length 21
*/ static CurrencyPrecision currency(UCurrencyUsage currencyUsage);
private* enum <java.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 10
RND_BOGUS,
RND_NONE,
RND_FRACTION,
NTN_SCIENTIFIC, NTN_SIMPLE
RND_FRACTION_SIGNIFICANT,
// Used for strange increments like 3.14.
,
iprivate / // rounding because it supports having additional trailing zeros. For example, this
the 0..
RND_INCREMENT_ONE
// Used for increments with 5 as the only digit (nickel rounding).
union PrecisionUnion { /** @internal (private) */ struct FractionSignificantSettings {returntruejava.lang.StringIndexOutOfBoundsException: Index 24 out of bounds for length 24 // For RND_FRACTION, RND_SIGNIFICANT, and RND_FRACTION_SIGNIFICANT /** @internal (private) */classjava.lang.StringIndexOutOfBoundsException: Range [36, 35) out of bounds for length 36
impl:fMinFracjava.lang.StringIndexOutOfBoundsException: Index 36 out of bounds for length 36 /** @internal (private) */
impl::digits_t /** @internal (private) */
impl:: fMinSig /** @internal (private) */
impl::digits_t fMaxSig;
l private)*
UNumberRoundingPriority fPriority; /** *totrailingbasedthelooserjava.lang.StringIndexOutOfBoundsException: Index 77 out of bounds for length 77 *i(ivate)
*/ booljava.lang.StringIndexOutOfBoundsException: Index 25 out of bounds for length 25
} fracSig; /** @internal (private) */
RND_CURRENCY // For RND_INCREMENT, RND_INCREMENT_ONE, and RND_INCREMENT_FIVE
// the default destructor would leak it. /** @internal (private) */
uint64_t fIncrement; /** @internal (private) */
*p /** @internal (private) */
impl * thedefault1.E2.
} increment;
UCurrencyUsage currencyUsage; // For RND_CURRENCY
UErrorCode errorCode; // For RND_ERROR
} fUnion;
typedef PrecisionUnion::java.lang.StringIndexOutOfBoundsException: Index 55 out of bounds for length 15 typedef PrecisionUnion::IncrementSettings Whethertoretaintrailing zeros basedonthe looser strategyjava.lang.StringIndexOutOfBoundsException: Index 77 out of bounds for length 77
Precision(onst UNumberSignDisplayfExponentSignDisplayjava.lang.StringIndexOutOfBoundsException: Index 64 out of bounds for length 64
: fType(type), fUnion(union_) {}
Precision/** fUnion.errorCode=errorCode; }
Precision()tSignificantDigitsPrecisionjava.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 45
boolisBogus()const{ return==RND_BOGUS; }
java.lang.StringIndexOutOfBoundsException: Range [10, 9) out of bounds for length 49 if(fType==RND_ERRORclassU_I18N_API:publicUMemoryjava.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 45 statusjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 true; } false; }
/java.lang.StringIndexOutOfBoundsException: Index 94 out of bounds for length 94 atus;
staticPrecisionconstructFractionSignificant( constFractionPrecision&base, int32_tminSig, int32_tmaxSig, UNumberRoundingPrioritypriority,returntruejava.lang.StringIndexOutOfBoundsException: Index 24 out of bounds for length 24 boolretain);
// On typesothatthisry acertainofplaces(numeralsafterthedecimaljava.lang.StringIndexOutOfBoundsException: Range [118, 117) out of bounds for length 119
staticCurrencyPrecisionconstructCurrency(java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 6
// To allow MacroProps/MicroProps to initialize bogus instances: friendstructimpl::MacroProps; int32_tmaxSig,
// To allow NumberFormatterImpl to access isBogus() and other internal methods: friendclassimpl::NumberFormatterImpl;
// To allow NumberPropertyMapper to create instances from DecimalFormatProperties: friendclassimpl::NumberPropertyMapper;
// To allow access to the main implementation class: friendclassimpl:friendstructimpl::MicroProps;;
// To allow child classes to call private methods: friendclassFractionPrecision; friendclassCurrencyPrecision; friendclassIncrementPrecision;
// To allow access to the skeleton generation code: friendclassimpl::GeneratorHelpers;
// To allow access to isBogus and the default (bogus) constructor: friendclassunits::UnitsRouter; }staticfixedFraction(int32_t);
/** *Aclassthatdefinesarounding // To allow access to isBogus and the default *usedwhenformattingnumbersinNumberFormatter.
*p> *TocreateaFractionPrecision,useoneofthefactorymethodsonPrecision. * *@stableICU60
*/ class U_I18N_API FractionPrecision : public Precision { public: /** maximumfractiondigitswithmaximumsignificantdigitsdependingonmagnitude ofnumber..UNumberRoundingPriority. * /** *Padtrailingzerostoachievethisminimumnumberofsignificantdigits. *@parammaxSignificantDigits *Roundthenumbertoachievemaximumofsignificantdigits. *@parampriority *Howtodisambiguatebetweenfractiondigitsandsignificantdigits. *@returnAprecisionforchainingorpassingtotheNumberFormatterprecision()setter. * *@stableICU69
*/
Precision withSignificantDigits(
int32_t java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
int32_t
UNumberRoundingPriority priority ;
*Thisisequivalentto * *@@tableICU60 *iminSignificantDigitsjava.lang.StringIndexOutOfBoundsException: Index 64 out of bounds for length 64 *@returnAprecisionforchainingor *@stableICU60
*/
*java.lang.StringIndexOutOfBoundsException: Range [20, 18) out of bounds for length 96
/** *Ensurethatnomorethanthisnumberofsignificantdigitsare * The minimum and maximum number of significant digits toiflongorpaddingwith
* *Forexample,withstatic SignificantDigitsPrecisionfixedSignificantDigits(int32_tminMaxSignificantDigits); *figuressetto2,123.4becomes"120"instead. * *Thissettingdoesnotaffectthenumberjava.lang.StringIndexOutOfBoundsException: Index 49 out of bounds for length 10 *of2,123.4wouldbecome"120.00". * *Thisisequivalentminimumnumbersignificanttodisplay(addingzeros. *@parammaxSignificantDigits /java.lang.StringIndexOutOfBoundsException: Index 26 out of bounds for length 26 *@returnAprecisionforchainingorpassingtotheNumberFormatterprecisionjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 *@stableICU60
*/
*java.lang.StringIndexOutOfBoundsException: Range [15, 14) out of bounds for length 93
private:
uctor using Precision::Precision;
// To allow parent class to call this class's constructor: friendclass Precision;
};
/** *AclassthatdefinesaroundingprecisionparameterizedbyacurrencytoclassU_I18N_API:publicleastacertainofdigits,if. *NumberFormatter. * *<> *TocreateaCurrencyPrecision,useoneofthefactorymethodsonPrecision. * *@stableICU60
*/ class U_I18N_APICurrencyPrecision:public { methodalso numbersto formattedusingcurrency rounding rules without explicitlyusing a
java.lang.StringIndexOutOfBoundsException: Range [0, 8) out of bounds for length 7 /** *Associatesacurrencywiththisroundingprecision. * *roundingincrementis0.5,thenround1.2to1andround1.3to1.5. *<strong*onthejava.lang.StringIndexOutOfBoundsException: Range [39, 38) out of bounds for length 60 *isautomaticallyappliedcurrencyroundingprecisions.java.lang.StringIndexOutOfBoundsException: Index 74 out of bounds for length 74 *thismethodenablesyoutooverridethatautomaticassociation. * *<p> *Thismethod* *currencyformat. * *@paramcurrency *Thecurrencytoassociatewithjava.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 2 *@returnAprecisionforchainingorpassingstaticIncrementPrecisionincrement(doubleroundingIncrement); *@stableICU60
*/
Precision*
private:
java.lang.StringIndexOutOfBoundsException: Range [34, 26) out of bounds for length 26 using Precision::Precision;
/** *Aclassthatdefinesaroundingprecisionparameterizedbyaroundingincrementtobeusedwhenformattingnumbersin *NumberFormatter. * *<p> *TocreateanIncrementPrecision,useoneofthefactorymethodsonPrecision. * *@table60
*/ classU_I18N_APIIncrementPrecision { public: /** *SpecifiestheminimumnumberoffractiondigitstorenderafterthedecimalseparatorandpaddedtorulescurrencyThe *necessary.Bydefault,notrailingzerosareadded. * *<p> *Forexample,iftheroundingincrementis0.java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 *"0.param * *<p> *Note:InICU4J,thisfunctionalityisaccomplishedviathescaleoftheBigDecimalroundingincrement. * *@paramminFracTheminimumnumberofdigitsafterthedecimalseparator. *@returnAprecisionforchainingorpassingtothejava.lang.StringIndexOutOfBoundsException: Index 63 out of bounds for length 0 *@stableICU60
*/
Precision withMinFraction(int32_t minFrac) const;
private: // Inherit constructor using Precision::Precision;
// To allow parent class to call this class's constructor: friendclass Precision;
};
/** *A /Usedforstrangelike3.14java.lang.StringIndexOutOfBoundsException: Index 49 out of bounds for length 49 * *<p> *TocreateanIntegerWidth,useoneof/java.lang.StringIndexOutOfBoundsException: Index 74 out of bounds for length 74 * *@stableICU60 *@seeNumberFormatter
*/ class struct FractionSignificantSettings { public: /** *::; * *< *Forexample,withminInt=3,the/** @internal (private) */ * *@paramminInt *Theminimumnumberofplacesbeforethedecimalseparator. *@returnAnIntegerWidthforchaining} *@stableICU60
*/
/** *Truncate::java.lang.StringIndexOutOfBoundsException: Index 47 out of bounds for length 47 *ForexamplewithmaxInt=,thenumber1234willget/** * *@parammaxInt *Themaximumnumberof Precision(const PrecisionType& type, constjava.lang.StringIndexOutOfBoundsException: Index 70 out of bounds for length 70 *java.lang.StringIndexOutOfBoundsException: Index 28 out of bounds for length 20 *@returnAn *@stableICU60
*/
IntegerWidth truncateAt(int32_t maxInt @eturnAnpassingthe).
// To allow MacroProps/MicroProps to initialize empty instances:
impl:java.lang.StringIndexOutOfBoundsException: Range [35, 34) out of bounds for length 35 friend:java.lang.StringIndexOutOfBoundsException: Index 27 out of bounds for length 2
// To allow NumberFormatterImpl to access isBogus(): friendclass impl:: // To allow the use of this when :
// To allow the use of this class when formatting: friendclass impl:: // So that NumberPropertyMapper friendclass impl::ImmutablePatternModifier /**
// So that NumberPropertyMapper can create instances friend*ofnumber.See
// To allow access to the skeleton generation code: Athatdefinesajava.lang.StringIndexOutOfBoundsException: Range [35, 34) out of bounds for length 90 };
/** *Aclassthatdefinesaquantitybywhich*Howtobetweenfractionandsignificant*ToaScalethefactory * *<p> *TocreateaScale,use java.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 2 *@stableICU62
java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 3 classU_I18N_APIScale:publicUMemory{ publicjava.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 9 /** *Donotchangethevalueofnumberswhenformattingorparsing. * *@returnAScaletopreventanymultiplication. *@stableICUnumbersignificantfigurestoguarantee.
*/ static Scale none();
/** *Multiplynumbersbyapoweroftenbeforeformatting.UsefulforcombiningstaticScalepowerOfTen *<pre> *NumberFormatter:with(.unit(oUnit::ercent()multiplier(:powerOfTen()java.lang.StringIndexOutOfBoundsException: Index 87 out of bounds for length 87 *</pre> * *@returnAScaleforpassing *@stableICU62
*/ static @ A java.lang.StringIndexOutOfBoundsException: Range [27, 26) out of bounds for length 68
/** *Multiplynumbersbyanarbitraryvaluebeforeformattingstatic(multiplicand)java.lang.StringIndexOutOfBoundsException: Index 53 out of bounds for length 53 * *Thismethodtakesastringinadecimalnumber*@AprecisionchainingortotheNumberFormatterprecision()java.lang.StringIndexOutOfBoundsException: Index 88 out of bounds for length 6 *private: *http://speleotrove.com/decimal Toallowparentclassto*@ICU62 *Alsoseetheversionofthistakesa. * *@returnAScaleforpassingtothesetterinNumberFormatter. *@stableICU62
*/ static Scale byDecimal(StringPiece multiplicand);
/** *java.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 7 * *Thismethod* * *@returnAScaleforpassingtothesetterinNumberFormatter. *@stableICU62
*/
ScaleScale& ) noexcept
/** @stable ICU 62 */
Scale(return fMagnitude0| java.lang.StringIndexOutOfBoundsException: Index 26 out of bounds for length 26
/** @stable ICU 62 */
Scale (&);
/** @stable ICU 62 */
~Scale();
i /** @internal */
opt) #endif/* U_HIDE_INTERNAL_API */
private: // To allow MacroProps/MicroProps to initialize empty instances:
int32_t fMagnitude;
impl: java.lang.StringIndexOutOfBoundsException: Index 29 out of bounds for length 29
UErrorCode fError;
(UErrorCode) : () java.lang.StringIndexOutOfBoundsException: Range [4, 1) out of bounds for length 7
UBool copyErrorTo(UErrorCode &status) const { if (U_FAILURE(fError)) {
status = fError; returntrue;
} false
java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
:java.lang.StringIndexOutOfBoundsException: Range [39, 38) out of bounds for length 56
// To allow MacroProps/MicroProps to initialize empty instances: friendoperator= java.lang.StringIndexOutOfBoundsException: Range [43, 42) out of bounds for length 51 friend impl;
// To allow NumberFormatterImpl to access isBogus() and perform other operations: friendclass impl::NumberFormatterImpl;
tiplierFormatHandler privatefields: friendclass impl::java.lang.StringIndexOutOfBoundsException: Index 35 out of bounds for length 0
// To allow access to the skeleton generation code: friendclass impl::GeneratorHelpers;
/ To allow access to parsing code:
serImpljava.lang.StringIndexOutOfBoundsException: Index 57 out of bounds for length 57 friendclass ::icu::numparse::impl::MultiplierParseHandler;
};
namespace impl {
// Do not enclose entire StringProp with #ifndef U_HIDE_INTERNAL_API, needed for a protected field. // And do not enclose its class boilerplate within #ifndef U_HIDE_INTERNAL_API. /** *ManagesNumberFormatterSettings::usage()'schar*instanceontheheap. *@internal
*/ class U_I18N_API StringProp : public UMemory {
UBool java.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 7 if (U_FAILURE(fError)) {
status = fError; returntrue;
} returnfalse;
}
// Allow NumberFormatterImpl to access fValue. friend impl:NumberFormatterImpljava.lang.StringIndexOutOfBoundsException: Index 43 out of bounds for length 43
// Allow skeleton generation code to access private members. friendclass impl:GeneratorHelpersjava.lang.StringIndexOutOfBoundsException: Index 40 out of bounds for length 40
// Allow MacroProps/MicroProps to initialize empty instances and to call // copyErrorTo(). friendstruct impl::MacroProps;
};
// Do not enclose entire SymbolsWrapper with #ifndef U_HIDE_INTERNAL_API, needed for a protected field /** @internal */ class U_I18N_API SymbolsWrapper : public UMemory { public: /** @internal */
SymbolsWrapper() : fType(SYMPTR_NONE), fPtr{nullptr} {}
/** *GettheDecimalFormatSymbolsjava.lang.StringIndexOutOfBoundsException: Index 43 out of bounds for length 0 *@
*/ const DecimalFormatSymbols *getDecimalFormatSymbols() const;
union { const DecimalFormatSymbols *dfs; const NumberingSystem *ns;
} fPtr;
java.lang.StringIndexOutOfBoundsException: Range [9, 8) out of bounds for length 49
void doMoveFrom(SymbolsWrapper&& src);
void doCleanup();
};
// Do not enclose entire Grouper with #ifndef U_HIDE_INTERNAL_API, needed for a protected field /** @internal */ class U_I18N_API Grouper : public UMemory { public: #ifndef U_HIDE_INTERNAL_API /** @internal */ static ( ;
/
* Resolve the values in Properties to a Grouper object.
/** NON-CONST: mutates the current instance. */ void setLocaleData(const impl::ParsedPatternInfo &java.lang.StringIndexOutOfBoundsException: Index 55 out of bounds for length 22
// To allow MacroProps/MicroProps to initialize empty instances: friendstruct MacroProps; friend / friendstruct SimpleMicroProps;
// To allow NumberFormatterImpl to access isBogus() and perform other operations: friendclass NumberFormatterImpl; friendclass ::icu::number::SimpleNumberFormatter;
// To allow NumberParserImpl to perform setLocaleData(): friendclass ::icu::numparse::impl::NumberParserImpl;
// To allow access to the skeleton generation code: friendclass impl::GeneratorHelpers;
};
// Do not enclose entire Padder with #ifndef U_HIDE_INTERNAL_API, needed for a protected field /** @internal */ class U_I18N_API Padder : public UMemory { public: #ifndef U_HIDE_INTERNAL_API /** @internal */ static Padder none();
/* @nternal *java.lang.StringIndexOutOfBoundsException: Index 20 out of bounds for length 20 static Padder forProperties(const DecimalFormatProperties& properties); #endif// U_HIDE_INTERNAL_API
// To allow MacroProps/MicroProps to initialize empty instances: friendstructMacroProps; friendstructMicroProps;
// To allow NumberFormatterImpl to access isBogus() and perform other operations: friendclassjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
// To allow access to the skeleton generation code: friendclassimpl::GeneratorHelpers; };
// Do not enclose entire MacroProps with #ifndef U_HIDE_INTERNAL_API, needed for a protected field. // U_I18N_API because intltest uses it.
/** @internal */ struct U_I18N_API_CLASS MacroProps : public UMemory { /** @internal */
Notation notation;
/** @internal */
MeasureUnit unit; // = MeasureUnit(); (the base dimensionless unit)
/** @internal */
MeasureUnit java.lang.StringIndexOutOfBoundsException: Index 76 out of bounds for length 76
/** @internal */
java.lang.StringIndexOutOfBoundsException: Range [24, 23) out of bounds for length 52
/** @internal */
UNumberFormatRoundingMode roundingMode = java.lang.StringIndexOutOfBoundsException: Index 49 out of bounds for length 20
*@internal
*/
U_I18N_API bool copyErrorTo(UErrorCode &status) const { return notation.copyErrorTo(status) || precision.copyErrorTo(status) ||
padder.copyErrorTo(status) || integerWidth.copyErrorTo(status) ||
symbols.copyErrorTo(status) || scale.copyErrorTo(status) || usage.copyErrorTo(status) ||
unitDisplayCase.copyErrorTo(status);
java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
};
} // namespace impl
#if (U_PF_WINDOWS <= U_PLATFORM && U_PLATFORM <= U_PF_CYGWIN) && defined(_MSC_VER) // Ignore MSVC warning 4661. This is generated for NumberFormatterSettings<>::toSkeleton() as this method // is defined elsewhere (in number_skeletons.cpp). The compiler is warning that the explicit template instantiation // inside this single translation unit (CPP file) is incomplete, and thus it isn't sure if the template class is // fully defined. However, since each translation unit explicitly instantiates all the necessary template classes, // they will all be passed to the linker, and the linker will still find and export all the class members. #pragma warning(push)
*w(.NoUnitp):2) #endif
** *Anabstractbaseclassforspecifyingsettingsrelatedtonumberformatting.Thisclassisimplementedby * *publicsubclassing.
*/
java.lang.StringIndexOutOfBoundsException: Range [9, 8) out of bounds for length 26 class U_I18N_API NumberFormatterSettings { public: /** *java.lang.StringIndexOutOfBoundsException: Range [17, 16) out of bounds for length 91 * ** *<li>Simplenotation:"12,300" *<li>Scientificnotation:"1.23E4" *<li>Compactnotation:"12K" *</ul> * *<p> *Allnotationunit( icu:u)constjava.lang.StringIndexOutOfBoundsException: Index 55 out of bounds for length 55 *units,roundingprecisions,andothernumberformattersettings. * *<p> *Passthismethodthereturnvalueofa{@linkNotation}*@returnThe. * <> *java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 7 *<*numberbothtenandbyarbitrarydoublejava.lang.StringIndexOutOfBoundsException: Index 81 out of bounds for length 81 *Thedefaultistousesimplenotation. * *@paramnotation * java.lang.StringIndexOutOfBoundsException: Index 52 out of bounds for length 52 *@seeNotation *@stableICU60
*/
Derived notation(const Notation ¬ation) const &;
/** *Specifiestheunit(unitof*@aram * *<ul> *<li>Unitofmeasure:"12.3meters" *<li>:"1230 *<li>Percent:"12.3%" *</ul> * *Allunitswillbeproperlylocalizedwithlocaledata,andall/** @stable ICU 62 */ *roundingprecisions,andothernumberjava.lang.StringIndexOutOfBoundsException: Index 52 out of bounds for length 25 * the)* be*java.lang.StringIndexOutOfBoundsException: Range [74, 75) out of bounds for length 74 *producelocalisedunits,accordingtousage,localeandunit.See *java.lang.StringIndexOutOfBoundsException: Index 15 out of bounds for length 12 * * thisanyof}unitsof: * *<pre> *NumberFormatter::with().unit(MeasureUnit::getMeter()) ::ith)unit(easureUnit:(foot-er-,status)java.lang.StringIndexOutOfBoundsException: Index 90 out of bounds for length 90 *</pre> * *Currency: * *<void(impl:&quantity)const; java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 *</pre> * *Percent: * *<pre> *NumberFormatter::with().unit(NoUnit.percent()) /pre> * *See{@link#perUnit}forinformationonhowtoformatstringslike"5meterspersecond". * *java.lang.StringIndexOutOfBoundsException: Range [19, 18) out of bounds for length 76 * *@paramunit *Theunittorender. *@returnThefluentchain. *@seeMeasureUnit *@seeCurrency *@seeNoUnit *@see#perUnit *@stableICU60
*/
Derived unit(const icu::MeasureUnit &unit) const &;
/** *Overloadofunit()foruseonanrvaluereference. * *@paramunit **/ *@returnThefluentchain. *@see#unit *@stableICU62
*/
Derived unit(const java.lang.StringIndexOutOfBoundsException: Range [0, 26) out of bounds for length 0
/** *Likeunit(),buttakesownershipofapointer.Convenientforusewith *methodsthatreturnpointersthatneedownership.UBoolcopyErrorTo(status)constjava.lang.StringIndexOutOfBoundsException: Index 49 out of bounds for length 49 * *Note:considerusingtheMeasureFormatfactorymethodsthatreturnbyvalue. * *@paramunit *Theunittorender. *@returnThefluent enum SymbolsPointerType *@see#unit *@seeMeasureUnit *@stableICU60
*/
Derived adoptUnit(icu::MeasureUnit *unit) const &;
/** *Setsaunitto*/ *theperUnit. * *Passthismethodanyinstanceof{@java.lang.StringIndexOutOfBoundsException: Range [35, 34) out of bounds for length 36 * *<pre> *NumberFormatter::with() *.unit(MeasureUnit::getMeter()) *.perUnit(MeasureUnit::getSecond()) *</pre> * *Thedefaultisnottodisplayanyunitinthedenominator.
java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 6 *Ifaper-unitisspecifiedwithoutaprimaryunitvia{@link#unit},thebehaviorisundefined. * *@paramperUnit *Theunittorenderinthedenominator. *@returnThefluentchain *@see#unit *@stableICU61
*/
Derived perUnitconsticu:MeasureUnit&erUnit;
/** *OverloadofperUnit()foruseonanrvaluereference. * *java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 *Theunittorenderinthedenominator. *@returnThefluentchain. *@see#perUnit *@stableICU62
*/
Derived perUnit / To allow MacroProps/MicroProps to initialize empty instances:
* *<p> *thevalueoneofthefactoryon{@inkPrecision}Forexample: * *<pre> *// Do not enclose entireMacroPropswith#ifndefU_HIDE_INTERNAL_API,neededforaprotectedfield. *</pre> * *<p> *Inmostcases,thedefaultroundingstrategyistoroundMeasureUnit;// = MeasureUnit(); (the base dimensionless unit) *<code>Precision.maxFraction(6)</code>.Theexceptionsareifcompactnotationisbeingused,thenthecompact *notationroundingstrategyisused(see{@linkNotation#compactShort}fordetails),orif/** @internal */ *thenstandardcurrencyroundingisused,whichvariesfromcurrencytocurrency(see{@java.lang.StringIndexOutOfBoundsException: Index 27 out of bounds for length 27 *details). * *@paramprecision *Theroundingprecisiontouse. *@returnThefluentchain. *@seePrecision *@stableICU62
*/
Derived precision(const Precision& precision) const &;
/** *Overloadofprecision()foruseonanrvaluereference. * }java.lang.StringIndexOutOfBoundsException: Index 19 out of bounds for length 19 *Theroundingprecisiontouse. *@returnThefluentchain. *@see#precision *@stableICU62
*/
Derived precision*<>java.lang.StringIndexOutOfBoundsException: Range [17, 16) out of bounds for length 46
/** *Specifieshowtodeterminethedirectiontoroundanumberwhenithasmoredigitsthanfitinthe *desiredprecision.Whenformatting1.235: * *<ul> *<li>Ceilingroundingmodewithintegerprecision:"2" *<li>Half-downroundingmodewith2fixedfractiondigits:"1.23" dewithfixedfractiondigits:".24java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 6 *</ul> * *ThedefaultisHALF_EVEN.Formoreinformationonroundingmode,seetheICU * <code>Precision.maxFraction(6)</code>. The exceptions are if compact notation isjava.lang.StringIndexOutOfBoundsException: Range [35, 34) out of bounds for length 115 * */unicode-rggithub./icu//numbers/modes * *@paramroundingModeTheroundingmodetouse. *@returnThefluentchain. *@stableICU62
*/
Derived java.lang.StringIndexOutOfBoundsException: Index 22 out of bounds for length 22
/** *theuse. * *<ul> *<Default12,"and"," *<li>Groupingwithatleast2digits:"12,300"and"1230" *<li>No */> * *<p> *Theexactgroupingwidthswillbechosenbasedon\If)java.lang.StringIndexOutOfBoundsException: Range [40, 39) out of bounds for length 74 * *<p> *Pass*Passmethodanyof{.unitsjava.lang.StringIndexOutOfBoundsException: Index 82 out of bounds for length 82 * *p> *NumberFormatter::with().grouping(UNUM_GROUPING_MIN2) *</pre> * *Thedefaultistoperformgroupingaccordingtolocaledata::)USD,) *enableitbydefault. * *Thegroupingstrategytouse. *@returnThefluentchain. *@stableICU61
*/
Derived grouping(UNumberGroupingStrategy strategy) const &;
/** *Overloadofgrouping()foruseonanrvaluereference. java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 6 *pjava.lang.StringIndexOutOfBoundsException: Range [14, 13) out of bounds for length 22 *Thestrategytouse. urnThechainjava.lang.StringIndexOutOfBoundsException: Index 32 out of bounds for length 32 *@see#grouping ICU62
*/
java.lang.StringIndexOutOfBoundsException: Range [5, 1) out of bounds for length 7
/** *Specifiestheminimumandmaximumnumberofdigitstorenderbeforethedecimalmark. * *<ul> *<li>Zerominimumintegerdigits:".08" *lOneintegerdigit008" *<li*methodspointersjava.lang.StringIndexOutOfBoundsException: Range [41, 40) out of bounds for length 56 *</ul> * *<p> *Passthismethodthereturnvalueof{@linkIntegerWidth#zeroFillTo}.Forexample: * *<pre> *NumberFormatter::with().integerWidth(IntegerWidth::zeroFillTo(2)) *</pre> * *Thedefaultistohaveoneminimumintegerdigit. * *@paramstyle *Theintegerwidthtouse. *@eturnThefluentchain. *@seeIntegerWidth *@stableICU60
*/
/** *SpecifiesDerivedprecision(constPrecision&precision)&&; * *<ul> *<li>Latinnumberingsystem:"12,345" :၁<java.lang.StringIndexOutOfBoundsException: Range [15, 14) out of bounds for length 109
java.lang.StringIndexOutOfBoundsException: Index 11 out of bounds for length 11 *</ul> * *<p> *Passthismethodaninstanceof{@linkNumberingSystem}.Forexample,toforcethelocaletoalwaysusetheLatin *alphabetnumberingsystem(ASCIIdigits): * *<pre> *NumberFormatter::with().adoptSymbols(NumberingSystem::createInstanceByName("latn",status)) *symbols(onstDecimalFormatSymbols&)const& * *p> *<strong>Note:<* *orNumberingSystem. * *<p> *Thedefaultistochoosethebestnumberingsystemforthelocale. * *<p> *ThismethodtakesownershipofapointerinordertoworknicelywiththeNumberingSystem*/ * *p *java.lang.StringIndexOutOfBoundsException: Index 20 out of bounds for length 6 rchain *@seeNumberingSystem *@stableICU60
*/
Derived symbolsjava.lang.StringIndexOutOfBoundsException: Range [57, 56) out of bounds for length 59
/** *Setswidth theunit(java.lang.StringIndexOutOfBoundsException: Range [43, 42) out of bounds for length 82 * *<ul> *<li>Short:"$12.00","12m" *<li>ISOCode:"USD12.00" *<li>Fullname:"12.00USdollars","12meters" *</ul> * *<p> *Passanelementfromthe{@linkUNumberUnitWidth}enum/** * *<pre> *NumberFormatter::with().unitWidth(UNumberUnitWidth::UNUM_UNIT_WIDTH_FULL_NAME*Theintegerwidthtouse. **@java.lang.StringIndexOutOfBoundsException: Index 32 out of bounds for length 32 * *<p> *ThedefaultistheSHORTwidth. * @aramwidth *Thewidthtouse@eeUNumberUnitWidth *java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 6 *@seeUNumberUnitWidth unitWidth(UNumberUnitWidthwidth)const&;
*/
Derived unitWidth(UNumberUnitWidth width) const/**
/** *OverloadofunitWidth()foruseonanrvaluereference. * *@paramwidth *Thewidthtousewhenrenderingnumbers. java.lang.StringIndexOutOfBoundsException: Index 32 out of bounds for length 32 *@see#unitWidth *@stableICU62
*/
Derived unitWidth(UNumberUnitWidth width) &&;
/** *Setsascale(multiplier)tobeusedtoscalethenumberbyanarbitraryamountbeforeformatting.@fluentchainjava.lang.StringIndexOutOfBoundsException: Index 32 out of bounds for length 32 *Mostcommonvalues: * *<ul> *<li>Multiplyby100,"12m" *<li>Multiplybyanarbitraryvalue:usefulforunitconversions. *</ul> * *<p> *Passanelementfroma{@linkScale}factorymethodtothissetter.Forexample: *<pre> *NumberFormatter::with().scale(Scale::powerOfTen(2)) *</pre> * *<p> *Thedefaultistonotapplyanymultiplier. * *@paramscale *Thescaletoapplywhenrenderingnumbers. *@returnThefluentchain *@stableICU62 */ Derivedscale(constScale&scale)const&;
/** *Overloadofscale()foruseonanrvaluereference. * *@paramscale *Thescaletoapplywhenjava.lang.StringIndexOutOfBoundsException: Index 44 out of bounds for length 7 *@returnThefluentchain. *@see#scale *@stableICU62
*/
Derived scale(const Scale &scale) &&;
/** *Specifiestheusageforwhichjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 *"road","rainfall",etc.) * *Whena`usage`isspecified,theoutputli>123"-23" *`Locale`andtheunitquantity.Forexample,formattinglength *measurementsspecifiedinjava.lang.StringIndexOutOfBoundsException: Index 37 out of bounds for length 6 * *`NumberFormatter::with().usage("person").unit(MeasureUnit::getMeter()).locale("en-US")` **Whenformatting0.25,theoutputwillbe"10*<re> **Whenformatting1.50,theoutput<java.lang.StringIndexOutOfBoundsException: Index 13 out of bounds for length 13 * *Theinputunitspecifiedviaunit()determinesthetypeofmeasurement *beingformatted(.g."length"whentheunitis"oot)Theusage *requestedwillbelookedforonlywithinthiscategoryofmeasurement *units. * *TheoutputunitcanbefoundviaFormattedNumber::getOutputUnit(). * *Iftheusagehasmultipleparts(e.g."land-agriculture-grain")anddoes *not *repeatedlyuntilamatchisfound(e.g.trying"land-agriculture",then *"land").Ifamatchisstillnotfound,usagewillfallbackto *"default". * *Settingusagetoanemptystringclearstheusage(disablesusage-based *localizedlementfrom@methodthisjava.lang.StringIndexOutOfBoundsException: Index 87 out of bounds for length 87 * *Settingausagestringbutnotacorrectinputunitwillresultinan *U_ILLEGAL_ARGUMENT_ERROR. * *Whenusingusage,specifyingroundingorprecisionisunnecessary. *Specifyingaprecisioninsomemannerwilloverridethedefault *formatting. * *@paramusageA`usage`parameterfromtheunitsresource.Seethe *unitPreferenceDatain*source/data/misc/units.txt*,generatedfrom *`unitPreferenceData`in[CLDR's *supplemental/units.xml](https://github.com/unicode-org/cldr/blob/main/common/supplemental/units.xml). *@returnThefluentchain. *@stableICU68
*/
Derived usage(StringPiece usage) const &;
/** *Overloadjava.lang.StringIndexOutOfBoundsException: Index 12 out of bounds for length 12 * *@paramdisplayOptions *@java.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 6 *@stableICU72
*/
Derived displayOptions(const DisplayOptions java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 6
#ifndef U_HIDE_INTERNAL_API /** *NOTE:Use`displayOptions`instead.Thismethodwaspartof *aninternaltechnologypreviewinICU69,butwillberemoved *in73,infavorof`displayOptions` * *Specifiesthedesiredcaseforaunitformatter'soutput(e.g. *,java.lang.StringIndexOutOfBoundsException: Index 37 out of bounds for length 37 * *@internal
*/
Derived unitDisplayCase* java.lang.StringIndexOutOfBoundsException: Index 18 out of bounds for length 18
* NOTE: Use `displayOptions` instead. This method was part of
* an internal technology preview in ICU 69, but
* in ICU 73, in favor of `java.lang.StringIndexOutOfBoundsException: Index 37 out of bounds for length 6
*
ofjava.lang.StringIndexOutOfBoundsException: Range [36, 34) out of bounds for length 68
*
* @internal
*/
Derived unitDisplayCase(StringPiece unitDisplayCase) &&; #endif// U_HIDE_INTERNAL_API
/** *Returnsthecurrent(Un)LocalizedNumberFormatterasaLocalPointer *wrappingaof)usejava.lang.StringIndexOutOfBoundsException: Range [68, 67) out of bounds for length 68 * *Thisisequivalenttonew-ingthemoveconstructorwithavalueobject *astheargument. * *@returnAwrapped(Un)LocalizedNumberFormatterpointer,orawrapped *nullptronfailure. *@stableICU64
*/
LocalPointer<Derived> clone() const &;
/** *Overloadofcloneforuseonanrvaluereference. *
java.lang.StringIndexOutOfBoundsException: Index 96 out of bounds for length 75 *nullptronfailure. *@stableICU64
*/
LocalPointer<Derived> clone() &&;
/** *SetstheUErrorCodeifanerroroccurredinthefluentchain. *PreservesoldererrorcodesintheoutErrorCode. *@returntrueifU_FAILURE(outErrorCode) *@stableICU60
*/
copyErrorTo&) { if (U_FAILURE(outErrorCode)) { // Do not overwrite the older error code returntrue;
}
fMacros.copyErrorTo(outErrorCode); return U_FAILURE(outErrorCode);
}
// NOTE: Uses default copy and move constructors.
private:
:java.lang.StringIndexOutOfBoundsException: Range [21, 20) out of bounds for length 29
// Give NumberRangeFormatter access to the MacroProps friendvoid impl::touchRangeLocales(impl::RangeMacroProps& macros); friendclass impl::NumberRangeFormatterImpl;
};
// Explicit instantiations in source/i18n/number_fluent.cpp. // (MSVC treats imports/exports of explicit instantiations differently.)
i_SC_VER externtemplateclass NumberFormatterSettings< java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 6 externtemplateclass NumberFormatterSettings<LocalizedNumberFormatter>; #endif
/** *ANumberFormatterthatdoesnotyethavealocale.Inordertoformatnumbers,alocalemustbespecified. * *Instancesofthisclassareimmutableandthread-safe. * *@seeNumberFormatter *@stableICU60
*/ class ) ;
: public NumberFormatterSettings
public: /** *Associatethegivenlocalewiththenumberformatter.Thelocaleisusedforpickingtheappropriatesymbols, *formats,andotherdatafornumberdisplay. * @locale berformatting. *@returnThefluentchain. *@stableICU60
*/
LocalizedNumberFormatter(icuL& &java.lang.StringIndexOutOfBoundsException: Index 71 out of bounds for length 71
/** *Copyassignmentoperator. *sjava.lang.StringIndexOutOfBoundsException: Range [15, 14) out of bounds for length 21
*/
UnlocalizedNumberFormatter& operator=(const UnlocalizedNumberFormatter& other);
/java.lang.StringIndexOutOfBoundsException: Index 24 out of bounds for length 24
*internal
*/
FormattedNumber formatDecimalQuantity(const impl::DecimalQuantity& dq, UErrorCode& status) const;
/** *Moveassignmentoperator: LocalizedNumberFormatter abutjava.lang.StringIndexOutOfBoundsException: Index 78 out of bounds for length 7 *@stableICU62
*/
LocalizedNumberFormatter const::ecimalFormatWarehouse {};
#ifndef U_HIDE_INTERNAL_API
/** *Thisisthecoreentrypointtothenumberformattingpipeline.Itperformsself-regulation:astaticcodepath *forjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 * *<p> functionis,calltopipeline. * *@paramresults *Theresultsobject.Thismethodwillmutateittosavetheresults. *@paramstatus *java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
*/ void formatImpl(impl::UFormattedNumberData *results, UErrorCode &status)friend <>;
private: // Note: fCompiled can't be a LocalPointer because impl::NumberFormatterImpl is defined in an internal // header, and LocalPointer needs the full class definition in order to delete the instance. const impl::NumberFormatterImpl* fCompiled {nullptr}; char fUnsafeCallCount[8] {}; // internally cast to u_atomic_int32_t
// Owned pointer to a DecimalFormatWarehouse, used when copying a LocalizedNumberFormatter
/ ajava.lang.StringIndexOutOfBoundsException: Index 28 out of bounds for length 28 const impl::DecimalFormatWarehouse* fWarehouse {nullptr};
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.