org.statcato.calculator
Class CompUnit
- java.lang.Object
-
- org.statcato.calculator.CompUnit
-
public class CompUnit extends java.lang.ObjectA computational unit. Contains the type of the computational object and the value (a double value or a vector of doubles).- Since:
- 1.0
- See Also:
Token
-
-
Constructor Summary
Constructors Constructor and Description CompUnit(int type, java.lang.Object value)Constructor, given the type of the unit and the value.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description java.util.Vector<java.lang.Double>getColumn()Returns the column represented by this unitdoublegetNumber()Returns the number value represented by this unit.intgetType()Returns the type of this unitjava.lang.StringtoString()
-
-
-
Constructor Detail
-
CompUnit
public CompUnit(int type, java.lang.Object value)Constructor, given the type of the unit and the value.- Parameters:
type- type of unit (Token.COLUMN or Token.NUMBER)value- Double for a number or Vector<Double> for a column- See Also:
Token
-
-
Method Detail
-
getNumber
public double getNumber()
Returns the number value represented by this unit.- Returns:
- number
-
getColumn
public java.util.Vector<java.lang.Double> getColumn()
Returns the column represented by this unit- Returns:
- column (vector of doubles)
-
getType
public int getType()
Returns the type of this unit- Returns:
- type
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-
DMelt 3.0 © DataMelt by jWork.ORG