Enum MeasureUnit
- java.lang.Object
-
- java.lang.Enum<MeasureUnit>
-
- org.pepstock.charba.client.intl.enums.MeasureUnit
-
- All Implemented Interfaces:
Serializable,Comparable<MeasureUnit>,Key
public enum MeasureUnit extends Enum<MeasureUnit> implements Key
Enumerated the untis of measure to configure the number formatting.
Possible values are core unit identifiers, defined here.
Pairs of simple units can be concatenated with "-per-" to make a compound unit.
There is no default value; if the style is "unit", the unit property must be provided.- Author:
- Andrea "Stock" Stocchero
-
-
Enum Constant Summary
Enum Constants Enum Constant Description ACRECore unit identifier for acre.BITCore unit identifier for bit.BYTECore unit identifier for byte.CELSIUSCore unit identifier for celsius.CENTIMETERCore unit identifier for centimeter.DAYCore unit identifier for day.DEGREECore unit identifier for degree.FAHRENHEITCore unit identifier for fahrenheit.FLUID_OUNCECore unit identifier for fluid-ounce.FOOTCore unit identifier for foot.GALLONCore unit identifier for gallon.GIGABITCore unit identifier for gigabit.GIGABYTECore unit identifier for gigabyte.GRAMCore unit identifier for gram.HECTARECore unit identifier for hectare.HOURCore unit identifier for hour.INCHCore unit identifier for inch.KILOBITCore unit identifier for kilobit.KILOBYTECore unit identifier for kilobyte.KILOGRAMCore unit identifier for kilogram.KILOMETERCore unit identifier for kilometer.LITERCore unit identifier for liter.MEGABITCore unit identifier for megabit.MEGABYTECore unit identifier for megabyte.METERCore unit identifier for meter.MILECore unit identifier for mile.MILE_SCANDINAVIANCore unit identifier for mile-scandinavian.MILLILITERCore unit identifier for milliliter.MILLIMETERCore unit identifier for millimeter.MILLISECONDCore unit identifier for millisecond.MINUTECore unit identifier for minute.MONTHCore unit identifier for month.OUNCECore unit identifier for ounce.PERCENTCore unit identifier for percent.PETABYTECore unit identifier for petabyte.POUNDCore unit identifier for pound.SECONDCore unit identifier for second.STONECore unit identifier for stone.TERABITCore unit identifier for terabit.TERABYTECore unit identifier for terabyte.WEEKCore unit identifier for week.YARDCore unit identifier for yard.YEARCore unit identifier for year.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Stringvalue()Returns the name value of propertystatic MeasureUnitvalueOf(String name)Returns the enum constant of this type with the specified name.static MeasureUnit[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
ACRE
public static final MeasureUnit ACRE
Core unit identifier for acre.
-
BIT
public static final MeasureUnit BIT
Core unit identifier for bit.
-
BYTE
public static final MeasureUnit BYTE
Core unit identifier for byte.
-
CELSIUS
public static final MeasureUnit CELSIUS
Core unit identifier for celsius.
-
CENTIMETER
public static final MeasureUnit CENTIMETER
Core unit identifier for centimeter.
-
DAY
public static final MeasureUnit DAY
Core unit identifier for day.
-
DEGREE
public static final MeasureUnit DEGREE
Core unit identifier for degree.
-
FAHRENHEIT
public static final MeasureUnit FAHRENHEIT
Core unit identifier for fahrenheit.
-
FLUID_OUNCE
public static final MeasureUnit FLUID_OUNCE
Core unit identifier for fluid-ounce.
-
FOOT
public static final MeasureUnit FOOT
Core unit identifier for foot.
-
GALLON
public static final MeasureUnit GALLON
Core unit identifier for gallon.
-
GIGABIT
public static final MeasureUnit GIGABIT
Core unit identifier for gigabit.
-
GIGABYTE
public static final MeasureUnit GIGABYTE
Core unit identifier for gigabyte.
-
GRAM
public static final MeasureUnit GRAM
Core unit identifier for gram.
-
HECTARE
public static final MeasureUnit HECTARE
Core unit identifier for hectare.
-
HOUR
public static final MeasureUnit HOUR
Core unit identifier for hour.
-
INCH
public static final MeasureUnit INCH
Core unit identifier for inch.
-
KILOBIT
public static final MeasureUnit KILOBIT
Core unit identifier for kilobit.
-
KILOBYTE
public static final MeasureUnit KILOBYTE
Core unit identifier for kilobyte.
-
KILOGRAM
public static final MeasureUnit KILOGRAM
Core unit identifier for kilogram.
-
KILOMETER
public static final MeasureUnit KILOMETER
Core unit identifier for kilometer.
-
LITER
public static final MeasureUnit LITER
Core unit identifier for liter.
-
MEGABIT
public static final MeasureUnit MEGABIT
Core unit identifier for megabit.
-
MEGABYTE
public static final MeasureUnit MEGABYTE
Core unit identifier for megabyte.
-
METER
public static final MeasureUnit METER
Core unit identifier for meter.
-
MILE
public static final MeasureUnit MILE
Core unit identifier for mile.
-
MILE_SCANDINAVIAN
public static final MeasureUnit MILE_SCANDINAVIAN
Core unit identifier for mile-scandinavian.
-
MILLILITER
public static final MeasureUnit MILLILITER
Core unit identifier for milliliter.
-
MILLIMETER
public static final MeasureUnit MILLIMETER
Core unit identifier for millimeter.
-
MILLISECOND
public static final MeasureUnit MILLISECOND
Core unit identifier for millisecond.
-
MINUTE
public static final MeasureUnit MINUTE
Core unit identifier for minute.
-
MONTH
public static final MeasureUnit MONTH
Core unit identifier for month.
-
OUNCE
public static final MeasureUnit OUNCE
Core unit identifier for ounce.
-
PERCENT
public static final MeasureUnit PERCENT
Core unit identifier for percent.
-
PETABYTE
public static final MeasureUnit PETABYTE
Core unit identifier for petabyte.
-
POUND
public static final MeasureUnit POUND
Core unit identifier for pound.
-
SECOND
public static final MeasureUnit SECOND
Core unit identifier for second.
-
STONE
public static final MeasureUnit STONE
Core unit identifier for stone.
-
TERABIT
public static final MeasureUnit TERABIT
Core unit identifier for terabit.
-
TERABYTE
public static final MeasureUnit TERABYTE
Core unit identifier for terabyte.
-
WEEK
public static final MeasureUnit WEEK
Core unit identifier for week.
-
YARD
public static final MeasureUnit YARD
Core unit identifier for yard.
-
YEAR
public static final MeasureUnit YEAR
Core unit identifier for year.
-
-
Method Detail
-
values
public static MeasureUnit[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (MeasureUnit c : MeasureUnit.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static MeasureUnit valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum type has no constant with the specified nameNullPointerException- if the argument is null
-
-