public enum UnitOfMeasurement extends Enum<UnitOfMeasurement>
Based on Recommendation N°. 20 - Codes for Units of Measure Used in International Trade
| Enum Constant and Description |
|---|
ARTICLE
A unit of count defining the number of articles (items).
|
DAY
The day count
|
HECTARE
The Hectare (ha).
|
HOUR
The Hour (h).
|
KILOGRAM
The Kilogram (kg).
|
KILOMETER
The Kilometer (km).
|
KILOWATT_HOUR
The Kilowatt hour (kWh).
|
LITRE
The Liter (l).
|
LUMP_SUM
The lump sum.
|
METER
The Meter (m).
|
METER_CUBIC
The cubic meter (m3).
|
METER_SQUARE
The square meter (m2).
|
MILLIMETER
The Millimeter (mm).
|
MILLIMETER_SQUARE
The square millimeter (mm2).
|
MINUTE
The Minute (min).
|
MONTH
The Month.
|
PAIR
The number of pairs.
|
PERCENT
The Percent (%).
|
SECOND
The Second (s).
|
SET
A number of objects grouped together to a set
|
TON_METRIC
The metric ton (t).
|
UNIT
A unit of count defining the number of pieces
|
WEEK
The week.
|
| Modifier and Type | Method and Description |
|---|---|
static UnitOfMeasurement |
getByCode(String code)
|
String |
getCode()
|
String |
getDescription()
|
String |
toString() |
static UnitOfMeasurement |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static UnitOfMeasurement[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final UnitOfMeasurement ARTICLE
public static final UnitOfMeasurement DAY
public static final UnitOfMeasurement HECTARE
public static final UnitOfMeasurement HOUR
public static final UnitOfMeasurement KILOGRAM
public static final UnitOfMeasurement KILOMETER
public static final UnitOfMeasurement KILOWATT_HOUR
public static final UnitOfMeasurement LITRE
public static final UnitOfMeasurement LUMP_SUM
public static final UnitOfMeasurement METER
public static final UnitOfMeasurement METER_CUBIC
public static final UnitOfMeasurement METER_SQUARE
public static final UnitOfMeasurement MILLIMETER
public static final UnitOfMeasurement MILLIMETER_SQUARE
public static final UnitOfMeasurement MINUTE
public static final UnitOfMeasurement MONTH
public static final UnitOfMeasurement PAIR
public static final UnitOfMeasurement PERCENT
public static final UnitOfMeasurement SECOND
public static final UnitOfMeasurement SET
public static final UnitOfMeasurement TON_METRIC
public static final UnitOfMeasurement UNIT
public static final UnitOfMeasurement WEEK
public static UnitOfMeasurement getByCode(String code)
Gets the type by code.
code - the codepublic String getDescription()
Gets the description.
public String toString()
toString in class Enum<UnitOfMeasurement>public static UnitOfMeasurement valueOf(String name)
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum type has no constant
with the specified nameNullPointerException - if the argument is nullpublic static UnitOfMeasurement[] values()
for (UnitOfMeasurement c : UnitOfMeasurement.values()) System.out.println(c);
Copyright © 2014 Konik.io. All Rights Reserved.