|
Java Units API Build 2004-02-06 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
ObjectConverter
MultiplyConverter
This class represents a multiply converter. A multiply converter multiplies numeric values by a constant scale factor.
Instances of this class are immutable.
| Field Summary |
| Fields inherited from class Converter |
IDENTITY |
| Constructor Summary | |
MultiplyConverter(double factor)
Creates a multiply converter with the specified scale factor. |
|
| Method Summary | |
Converter |
concatenate(Converter converter)
Concatenates this converter with another converter. |
double |
convert(double amount)
Converts a double value. |
double |
derivative(double x)
Returns this converter derivative for the specified x value. |
Converter |
inverse()
Returns the inverse of this converter. |
boolean |
isLinear()
Indicates if this converter is linear. |
| Methods inherited from class Converter |
equals, hashCode |
| Methods inherited from class Object |
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public MultiplyConverter(double factor)
factor - the scale factor.| Method Detail |
public Converter inverse()
Converterx is a valid
value, then x == inverse().convert(convert(x)) to within
the accuracy of computer arithmetic.
inverse in class Converterpublic double convert(double amount)
Converter
convert in class Converteramount - the numeric value to convert.
public double derivative(double x)
Converterx value. For linear converters, this method returns
a constant (the linear factor) for all x values.
derivative in class Converterx - the value for which the derivative is calculated.
public boolean isLinear()
Converterconvert(u + v) == convert(u) + convert(v) and
convert(r * u) == r * convert(u).
isLinear in class Convertertrue if this converter is linear;
false otherwise.public Converter concatenate(Converter converter)
Converter
concatenate in class Converterconverter - the other converter.
|
Java Units API Build 2004-02-06 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
|
Symbols, terms and definitions | JSR-108 project |