public class FloatElectricalResistance extends AbstractFloatScalarRel<ElectricalResistanceUnit,FloatElectricalResistance>
FloatScalar.Rel<ElectricalResistanceUnit> value = new FloatScalar.Rel<ElectricalResistanceUnit>(100.0, ElectricalResistanceUnit.SI);we can now write:
FloatElectricalResistance value = new FloatElectricalResistance(100.0, ElectricalResistanceUnit.SI);The compiler will automatically recognize which units belong to which quantity, and whether the quantity type and the unit used are compatible.
Copyright (c) 2013-2018 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See DJUNITS License.
$LastChangedDate: 2018-01-28 03:17:44 +0100 (Sun, 28 Jan 2018) $, @version $Revision: 256 $, by $Author: averbraeck $,
initial version Sep 5, 2015
Modifier and Type | Field and Description |
---|---|
static FloatElectricalResistance |
NaN
constant with value NaN.
|
static FloatElectricalResistance |
NEG_MAXVALUE
constant with value -MAX_VALUE.
|
static FloatElectricalResistance |
NEGATIVE_INFINITY
constant with value NEGATIVE_INFINITY.
|
static FloatElectricalResistance |
POS_MAXVALUE
constant with value MAX_VALUE.
|
static FloatElectricalResistance |
POSITIVE_INFINITY
constant with value POSITIVE_INFINITY.
|
static FloatElectricalResistance |
ZERO
constant with value zero.
|
si
Constructor and Description |
---|
FloatElectricalResistance(double value,
ElectricalResistanceUnit unit)
Construct FloatElectricalResistance scalar using a double value.
|
FloatElectricalResistance(FloatElectricalResistance value)
Construct FloatElectricalResistance scalar.
|
FloatElectricalResistance(float value,
ElectricalResistanceUnit unit)
Construct FloatElectricalResistance scalar.
|
Modifier and Type | Method and Description |
---|---|
static FloatElectricalResistance |
createSI(float value)
Construct FloatElectricalResistance scalar.
|
FloatDimensionless |
divideBy(FloatElectricalResistance v)
Calculate the division of FloatElectricalResistance and FloatElectricalResistance, which results in a FloatDimensionless
scalar.
|
FloatElectricalResistance |
instantiateRel(float value,
ElectricalResistanceUnit unit)
Construct a new Relative Immutable FloatScalar of the right type.
|
static FloatElectricalResistance |
interpolate(FloatElectricalResistance zero,
FloatElectricalResistance one,
float ratio)
Interpolate between two values.
|
static FloatElectricalResistance |
max(FloatElectricalResistance r1,
FloatElectricalResistance r2)
Return the maximum value of two relative scalars.
|
static FloatElectricalResistance |
max(FloatElectricalResistance r1,
FloatElectricalResistance r2,
FloatElectricalResistance... rn)
Return the maximum value of more than two relative scalars.
|
static FloatElectricalResistance |
min(FloatElectricalResistance r1,
FloatElectricalResistance r2)
Return the minimum value of two relative scalars.
|
static FloatElectricalResistance |
min(FloatElectricalResistance r1,
FloatElectricalResistance r2,
FloatElectricalResistance... rn)
Return the minimum value of more than two relative scalars.
|
FloatElectricalPotential |
multiplyBy(FloatElectricalCurrent v)
Calculate the multiplication of FloatElectricalResistance and FloatElectricalCurrent, which results in a
FloatElectricalPotential scalar.
|
abs, ceil, divideBy, floor, minus, multiplyBy, neg, plus, rint, round
compareTo, doubleValue, eq, eq0, equals, floatValue, ge, ge0, getInUnit, getInUnit, getSI, gt, gt0, hashCode, intValue, le, le0, longValue, lt, lt0, ne, ne0, toString, toString, toString, toString
expressAsSIUnit, expressAsSpecifiedUnit, getUnit, isAbsolute, isRelative, setDisplayUnit
byteValue, shortValue
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
DIV, MULT, POW
public static final FloatElectricalResistance ZERO
public static final FloatElectricalResistance NaN
public static final FloatElectricalResistance POSITIVE_INFINITY
public static final FloatElectricalResistance NEGATIVE_INFINITY
public static final FloatElectricalResistance POS_MAXVALUE
public static final FloatElectricalResistance NEG_MAXVALUE
public FloatElectricalResistance(float value, ElectricalResistanceUnit unit)
value
- float valueunit
- unit for the float valuepublic FloatElectricalResistance(FloatElectricalResistance value)
value
- Scalar from which to construct this instancepublic FloatElectricalResistance(double value, ElectricalResistanceUnit unit)
value
- double valueunit
- unit for the resulting float valuepublic final FloatElectricalResistance instantiateRel(float value, ElectricalResistanceUnit unit)
instantiateRel
in class AbstractFloatScalarRel<ElectricalResistanceUnit,FloatElectricalResistance>
value
- the float valueunit
- the unitpublic static final FloatElectricalResistance createSI(float value)
value
- float value in SI unitspublic static FloatElectricalResistance interpolate(FloatElectricalResistance zero, FloatElectricalResistance one, float ratio)
zero
- the low valueone
- the high valueratio
- the ratio between 0 and 1, inclusivepublic static FloatElectricalResistance max(FloatElectricalResistance r1, FloatElectricalResistance r2)
r1
- the first scalarr2
- the second scalarpublic static FloatElectricalResistance max(FloatElectricalResistance r1, FloatElectricalResistance r2, FloatElectricalResistance... rn)
r1
- the first scalarr2
- the second scalarrn
- the other scalarspublic static FloatElectricalResistance min(FloatElectricalResistance r1, FloatElectricalResistance r2)
r1
- the first scalarr2
- the second scalarpublic static FloatElectricalResistance min(FloatElectricalResistance r1, FloatElectricalResistance r2, FloatElectricalResistance... rn)
r1
- the first scalarr2
- the second scalarrn
- the other scalarspublic final FloatDimensionless divideBy(FloatElectricalResistance v)
v
- FloatElectricalResistance scalarpublic final FloatElectricalPotential multiplyBy(FloatElectricalCurrent v)
v
- FloatElectricalResistance scalarCopyright © 2015–2018 Delft University of Technology. All rights reserved.