public class TemperatureUnit extends LinearUnit<TemperatureUnit>
Copyright (c) 2015-2019 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See DJUNITS License.
$LastChangedDate: 2019-01-18 00:35:01 +0100 (Fri, 18 Jan 2019) $, @version $Revision: 324 $, by $Author: averbraeck $,
initial version Jun 5, 2014
Modifier and Type | Field and Description |
---|---|
static TemperatureUnit |
DEGREE_CELSIUS
Degree Celsius.
|
static TemperatureUnit |
DEGREE_FAHRENHEIT
Degree Fahrenheit.
|
static TemperatureUnit |
DEGREE_RANKINE
Degree Rankine.
|
static TemperatureUnit |
DEGREE_REAUMUR
Degree Reaumur.
|
static TemperatureUnit |
KELVIN
Kelvin.
|
static TemperatureUnit |
SI
The SI unit for temperature is Kelvin.
|
STANDARD_UNITS
Constructor and Description |
---|
TemperatureUnit(String name,
String abbreviation,
UnitSystem unitSystem,
TemperatureUnit referenceUnit,
double scaleFactorToStandardUnit,
double offsetToKelvin)
Build a user-defined TemperatureUnit with a conversion factor and offset to Kelvin.
|
Modifier and Type | Method and Description |
---|---|
String |
getSICoefficientsString() |
TemperatureUnit |
getStandardUnit() |
equals, equalsIgnoreNaming, getScale, getScaleFactor, hashCode
generateHashCode, getAbbreviation, getAbbreviationKey, getAllUnitsOfThisType, getName, getNameKey, getSICoefficients, getUnits, getUnitSystem, isBaseSIUnit, isLocalizable, lookupOrCreateSIUnitWithSICoefficients, lookupOrCreateUnitWithSICoefficients, lookupUnitWithSICoefficients, toString
public static final TemperatureUnit SI
public static final TemperatureUnit KELVIN
public static final TemperatureUnit DEGREE_CELSIUS
public static final TemperatureUnit DEGREE_FAHRENHEIT
public static final TemperatureUnit DEGREE_RANKINE
public static final TemperatureUnit DEGREE_REAUMUR
public TemperatureUnit(String name, String abbreviation, UnitSystem unitSystem, TemperatureUnit referenceUnit, double scaleFactorToStandardUnit, double offsetToKelvin)
name
- String; the long name of the unitabbreviation
- String; the abbreviation of the unitunitSystem
- UnitSystem; the unit system, e.g. SI or ImperialreferenceUnit
- TemperatureUnit; the unit to convert toscaleFactorToStandardUnit
- double; multiply by this number to convert to the standard unitoffsetToKelvin
- double; the offsetToKelvin to add to convert to the standard (e.g., SI) unitpublic final TemperatureUnit getStandardUnit()
getStandardUnit
in class Unit<TemperatureUnit>
public final String getSICoefficientsString()
getSICoefficientsString
in class Unit<TemperatureUnit>
Copyright © 2015–2019 Delft University of Technology. All rights reserved.