|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnetkit.graph.Attribute
netkit.graph.AttributeContinuous
public final class AttributeContinuous
This class handles attributes that are of type CONTINUOUS. CONTINUOUS types can have real numerical values and are represented internally as java double types. This class is immutable.
Attributes
,
SchemaReader
Constructor Summary | |
---|---|
AttributeContinuous(java.lang.String name)
The constructor must be provided the name for this attribute. |
Method Summary | |
---|---|
java.lang.String |
formatForOutput(double value)
Formats the supplied value from this attribute as a String for output. |
double |
parseAndInsert(java.lang.String token)
Parses the supplied string token for insertion into this attribute and converts the token into a double value; a "?" token results in NaN. |
Methods inherited from class netkit.graph.Attribute |
---|
getName, getType, toString |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public AttributeContinuous(java.lang.String name)
name
- a String representing the name of this attribute.Method Detail |
---|
public double parseAndInsert(java.lang.String token)
parseAndInsert
in class Attribute
token
- the string value to parse.
java.lang.NumberFormatException
- if the token does not contain a
parsable double.public java.lang.String formatForOutput(double value)
Attribute
formatForOutput
in class Attribute
value
- a double to be converted into an output String.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |