|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectetomica.units.CompoundUnit
public class CompoundUnit
| Constructor Summary | |
|---|---|
CompoundUnit(Unit[] units,
double[] exponents)
|
|
CompoundUnit(Unit[] units,
double[] exponents,
String name,
String symbol)
|
|
| Method Summary | |
|---|---|
Dimension |
dimension()
Returns the dimension of the unit. |
double |
fromSim(double x)
Takes the given value in simulation units and converts it to class units (considering prefix). |
boolean |
prefixAllowed()
Indicates if the unit is appropriate for use with a prefix. |
String |
symbol()
Returns the symbol of unit, such as "g" for grams. |
double |
toSim(double x)
Takes the given value in class units (considering prefix) and converts it to simulation units. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public CompoundUnit(Unit[] units,
double[] exponents)
public CompoundUnit(Unit[] units,
double[] exponents,
String name,
String symbol)
| Method Detail |
|---|
public Dimension dimension()
Unit
dimension in interface Unitpublic double toSim(double x)
Unit
toSim in interface Unitx - a value in units of the class
public double fromSim(double x)
Unit
fromSim in interface Unitx - a value in simulation units
public String symbol()
Unit
symbol in interface Unitpublic boolean prefixAllowed()
Unit
prefixAllowed in interface Unit
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||