public class MoneyPerEnergyUnit extends LinearUnit<MoneyPerEnergyUnit>
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-03-02 19:06:46 +0100 (Sat, 02 Mar 2019) $, @version $Revision: 342 $, by $Author: averbraeck $,
initial version Sep 5, 2015
Modifier and Type | Field and Description |
---|---|
static MoneyPerEnergyUnit |
EUR_PER_KILOWATTHOUR
Euro per kWh.
|
static MoneyPerEnergyUnit |
EUR_PER_MEGAJOULE
Euro per MJ.
|
static MoneyPerEnergyUnit |
EUR_PER_MEGAWATTHOUR
Euro per MWh.
|
static MoneyPerEnergyUnit |
USD_PER_KILOWATTHOUR
US$ per kWh.
|
static MoneyPerEnergyUnit |
USD_PER_MEGAJOULE
US$ per MJ.
|
static MoneyPerEnergyUnit |
USD_PER_MEGAWATTHOUR
US$ per MWh.
|
STANDARD_UNITS
Constructor and Description |
---|
MoneyPerEnergyUnit(MoneyUnit moneyUnit,
EnergyUnit energyUnit,
String name,
String abbreviation)
Build a user-defined money per energy unit from a money unit and an energy unit.
|
MoneyPerEnergyUnit(String name,
String abbreviation,
MoneyPerEnergyUnit referenceUnit,
double scaleFactorToReferenceUnit)
Build a user-defined MoneyPerEnergyUnitit with a conversion factor to another MoneyPerEnergyUnit.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object obj) |
EnergyUnit |
getEnergyUnit() |
MoneyUnit |
getMoneyUnit() |
String |
getSICoefficientsString() |
static MoneyPerEnergyUnit |
getStandardMoneyPerEnergyUnit() |
MoneyPerEnergyUnit |
getStandardUnit() |
int |
hashCode() |
protected static void |
setStandardUnit(MoneyUnit standardMoneyUnit)
Set the standard MoneyPerEnergyUnit in case the standard MoneyUnit changes, as the standard money unit is flexible.
|
equalsIgnoreNaming, getScale, getScaleFactor
generateHashCode, getAbbreviation, getAbbreviationKey, getAllUnitsOfThisType, getDefaultLocaleAbbreviation, getDefaultLocaleName, getDefaultLocaleTextualRepresentation, getDefaultLocaleTextualRepresentations, getDefaultTextualRepresentation, getName, getSICoefficients, getTextualRepresentations, getUnits, getUnitSystem, isBaseSIUnit, isLocalizable, lookupOrCreateSIUnitWithSICoefficients, lookupOrCreateUnitWithSICoefficients, lookupUnitWithSICoefficients, toString
public static final MoneyPerEnergyUnit EUR_PER_KILOWATTHOUR
public static final MoneyPerEnergyUnit EUR_PER_MEGAWATTHOUR
public static final MoneyPerEnergyUnit EUR_PER_MEGAJOULE
public static final MoneyPerEnergyUnit USD_PER_KILOWATTHOUR
public static final MoneyPerEnergyUnit USD_PER_MEGAWATTHOUR
public static final MoneyPerEnergyUnit USD_PER_MEGAJOULE
public MoneyPerEnergyUnit(MoneyUnit moneyUnit, EnergyUnit energyUnit, String name, String abbreviation)
moneyUnit
- MoneyUnit; the unit of money for the money per energy unit, e.g., EURenergyUnit
- EnergyUnit; the unit of energy for the money per energy unit, e.g., kWhname
- String; the key to the locale file for the long name of the unitabbreviation
- String; the key to the locale file for the abbreviation of the unitpublic MoneyPerEnergyUnit(String name, String abbreviation, MoneyPerEnergyUnit referenceUnit, double scaleFactorToReferenceUnit)
name
- String; the long name of the unitabbreviation
- String; the abbreviation of the unitreferenceUnit
- MoneyPerEnergyUnit; the unit to convert toscaleFactorToReferenceUnit
- double; multiply a value in this unit by the factor to convert to the given reference
unitpublic final MoneyUnit getMoneyUnit()
public final EnergyUnit getEnergyUnit()
protected static void setStandardUnit(MoneyUnit standardMoneyUnit)
standardMoneyUnit
- MoneyUnit; the new standard money unit.public final MoneyPerEnergyUnit getStandardUnit()
getStandardUnit
in class Unit<MoneyPerEnergyUnit>
public static MoneyPerEnergyUnit getStandardMoneyPerEnergyUnit()
public final String getSICoefficientsString()
getSICoefficientsString
in class Unit<MoneyPerEnergyUnit>
public int hashCode()
hashCode
in class LinearUnit<MoneyPerEnergyUnit>
public boolean equals(Object obj)
equals
in class LinearUnit<MoneyPerEnergyUnit>
Copyright © 2015–2019 Delft University of Technology. All rights reserved.