public class MassUnit extends Unit<MassUnit>
Copyright (c) 2015 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See DJUNITS License.
$LastChangedDate: 2015-10-04 20:48:33 +0200 (Sun, 04 Oct 2015) $, @version $Revision: 87 $, by $Author: averbraeck $, initial
version May 15, 2014
| Modifier and Type | Field and Description |
|---|---|
static MassUnit |
DALTON
dalton.
|
static MassUnit |
GRAM
gram.
|
static MassUnit |
KILOGRAM
kilogram.
|
static MassUnit |
OUNCE
pound.
|
static MassUnit |
POUND
pound.
|
static MassUnit |
SI
The SI unit for mass is kilogram.
|
static MassUnit |
TON_LONG
long ton = 2240 lb.
|
static MassUnit |
TON_METRIC
metric ton = 1000 kg.
|
static MassUnit |
TON_SHORT
short ton = 2000 lb.
|
static MassUnit |
TONNE
metric ton = 1000 kg.
|
| Constructor and Description |
|---|
MassUnit(String name,
String abbreviation,
UnitSystem unitSystem,
MassUnit referenceUnit,
double conversionFactorToReferenceUnit)
Build a user-defined MassUnit with a conversion factor to another MassUnit.
|
| Modifier and Type | Method and Description |
|---|---|
String |
getSICoefficientsString() |
MassUnit |
getStandardUnit() |
equals, getAbbreviation, getAbbreviationKey, getAllUnitsOfThisType, getConversionFactorToStandardUnit, getName, getNameKey, getSICoefficients, getUnits, getUnitSystem, hashCode, isLocalizable, lookupOrCreateSIUnitWithSICoefficients, lookupOrCreateUnitWithSICoefficients, lookupUnitWithSICoefficients, toStringpublic static final MassUnit SI
public static final MassUnit KILOGRAM
public static final MassUnit GRAM
public static final MassUnit POUND
public static final MassUnit OUNCE
public static final MassUnit TON_LONG
public static final MassUnit TON_SHORT
public static final MassUnit TON_METRIC
public static final MassUnit TONNE
public static final MassUnit DALTON
public MassUnit(String name, String abbreviation, UnitSystem unitSystem, MassUnit referenceUnit, double conversionFactorToReferenceUnit)
name - the long name of the unitabbreviation - the abbreviation of the unitunitSystem - the unit system, e.g. SI or ImperialreferenceUnit - the unit to convert toconversionFactorToReferenceUnit - multiply a value in this unit by the factor to convert to the given reference unitpublic final MassUnit getStandardUnit()
getStandardUnit in class Unit<MassUnit>public final String getSICoefficientsString()
getSICoefficientsString in class Unit<MassUnit>Copyright © 2015 Delft University of Technology. All rights reserved.