com.rubecula.jquantity
Class UnitsFoundation
java.lang.Object
com.rubecula.util.Item
com.rubecula.jquantity.BaseUnit
com.rubecula.jquantity.UnitsFoundation
- All Implemented Interfaces:
- com.rubecula.util.Auditable, Comparable, com.rubecula.util.Identifiable, Measurable, com.rubecula.util.Nameable, com.rubecula.util.Presentable, Serializable
- Direct Known Subclasses:
- Units
- public abstract class UnitsFoundation
- extends BaseUnit
- implements com.rubecula.util.Nameable, com.rubecula.util.Auditable
The public abstract class UnitsFoundation is the base class
from which the other Units (Measurable) classes are derived.
- Version:
- $Revision: 1.8 $
- Author:
- Robin Hillyard
- See Also:
- Serialized Form
Field Summary |
protected UnitsName |
_Name
The name by which this UnitsFoundation will be identified. |
private static boolean |
debug
|
Fields inherited from class com.rubecula.util.Item |
JQUANTITY_TEST |
Methods inherited from class com.rubecula.util.Item |
compareTo, Debug, getClassNameShort, getType, IsDebug, present, SetDebug, test, test, Wrap |
Methods inherited from interface com.rubecula.util.Presentable |
makePresentableInstance, present |
_Name
protected UnitsName _Name
- The name by which this UnitsFoundation will be identified.
debug
private static boolean debug
UnitsFoundation
UnitsFoundation()
UnitsFoundation
UnitsFoundation(UnitsName name)
UnitsFoundation
UnitsFoundation(UnitsFoundation that)
setIdentifier
public void setIdentifier(String identifier)
- Method to set a specific identifier to an object.
- Specified by:
setIdentifier
in interface com.rubecula.util.Nameable
- Parameters:
identifier
- String: the identifier to associate with the object
getIdentifier
public String getIdentifier()
- Method to get the specific identifier for an object.
- Specified by:
getIdentifier
in interface com.rubecula.util.Identifiable
- Returns:
- String: the identifier.
audit
public String audit(String label)
- Method to return a detailed string from an arithmetical object for
debugging purposes.
- Specified by:
audit
in interface com.rubecula.util.Auditable
- Parameters:
label
- String: the label to associate with the data
- Returns:
- the detailed string.
audit
public String audit()
- Method to return a detailed (unlabeled) string from an Auditable object
for debugging purposes.
- Specified by:
audit
in interface com.rubecula.util.Auditable
- Returns:
- the detailed string.
audit
public void audit(PrintStream out,
String label)
- Specified by:
audit
in interface com.rubecula.util.Auditable
isNumber
public boolean isNumber()
- Method to determine if this is dimensionless (i.e. unitless).
- Specified by:
isNumber
in interface Measurable
- Overrides:
isNumber
in class BaseUnit
- Returns:
- true if not in any System.
normalize
final int normalize()
toString
public abstract String toString(int sysIndex)
toString
public String toString()
setName
public final void setName(UnitsName name,
boolean force,
int sysIndex)
setName
public final void setName(UnitsName name,
boolean force)
setName
public final void setName(String nameAbbrev,
int exponent,
boolean force)
setName
public final void setName(String nameAbbrev,
boolean force)
setName
public final void setName(UnitsName name)
setName
public final void setName(String name)
monitor
void monitor(String method,
String[] args,
String result)