Package com.ibm.icu.impl.number
Class MicroProps
- java.lang.Object
-
- com.ibm.icu.impl.number.MicroProps
-
- All Implemented Interfaces:
MicroPropsGenerator
,java.lang.Cloneable
public class MicroProps extends java.lang.Object implements java.lang.Cloneable, MicroPropsGenerator
MicroProps is the first MicroPropsGenerator that should be should be called, producing an initialized MicroProps instance that will be passed on and modified throughout the rest of the chain of MicroPropsGenerator instances.
-
-
Field Summary
Fields Modifier and Type Field Description java.lang.String
currencyAsDecimal
NumberFormatter.DecimalSeparatorDisplay
decimal
private boolean
exhausted
java.lang.String
gender
Grouper
grouping
private boolean
immutable
int
indexOfQuantity
Points to quantity position, -1 if the position is not set yet.IntegerWidth
integerWidth
java.util.List<Measure>
mixedMeasures
Contains all the measures.Modifier
modInner
Modifier
modMiddle
Modifier
modOuter
java.lang.String
nsName
MeasureUnit
outputUnit
Padder
padding
Precision
rounder
NumberFormatter.SignDisplay
sign
DecimalFormatSymbols
symbols
boolean
useCurrency
-
Constructor Summary
Constructors Constructor Description MicroProps(boolean immutable)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Object
clone()
MicroProps
processQuantity(DecimalQuantity quantity)
As MicroProps is the "base instance", this implementation ofMircoPropsGenerator.processQuantity()
just ensures that the outputmicros
is correctly initialized.
-
-
-
Field Detail
-
sign
public NumberFormatter.SignDisplay sign
-
symbols
public DecimalFormatSymbols symbols
-
nsName
public java.lang.String nsName
-
padding
public Padder padding
-
decimal
public NumberFormatter.DecimalSeparatorDisplay decimal
-
integerWidth
public IntegerWidth integerWidth
-
modOuter
public Modifier modOuter
-
modMiddle
public Modifier modMiddle
-
modInner
public Modifier modInner
-
rounder
public Precision rounder
-
grouping
public Grouper grouping
-
useCurrency
public boolean useCurrency
-
gender
public java.lang.String gender
-
currencyAsDecimal
public java.lang.String currencyAsDecimal
-
immutable
private final boolean immutable
-
outputUnit
public MeasureUnit outputUnit
-
mixedMeasures
public java.util.List<Measure> mixedMeasures
Contains all the measures.
-
indexOfQuantity
public int indexOfQuantity
Points to quantity position, -1 if the position is not set yet.
-
exhausted
private volatile boolean exhausted
-
-
Method Detail
-
processQuantity
public MicroProps processQuantity(DecimalQuantity quantity)
As MicroProps is the "base instance", this implementation ofMircoPropsGenerator.processQuantity()
just ensures that the outputmicros
is correctly initialized.For the "safe" invocation of this function, micros must not be *this, such that a copy of the base instance is made. For the "unsafe" path, this function can be used only once, because the base MicroProps instance will be modified and thus not be available for re-use.
- Specified by:
processQuantity
in interfaceMicroPropsGenerator
- Parameters:
quantity
- The quantity for consideration and optional mutation.- Returns:
- an initialized MicroProps instance.
-
clone
public java.lang.Object clone()
- Overrides:
clone
in classjava.lang.Object
-
-