Package ca.spatial.table
Class AppendColumnSpec
java.lang.Object
ca.spatial.table.AppendColumnSpec
This class holds the specification of a column in an
AppendStore. The specification includes the column name,
data type, width and number of digits of precision after the
decimal point.
In addition, the specification also contains the expressions that will be evaluated on each appended table in order to generate the data for this table.
- See Also:
AppendStore
,AppendStoreBuilder
-
Constructor Summary
ConstructorsConstructorDescriptionAppendColumnSpec(String name, int type, int width, int dec)
Create a column definition.AppendColumnSpec(String name, String type, int width, int dec)
Create a column definition. -
Method Summary
Modifier and TypeMethodDescriptionaddExpression(int index, String expression)
Add an expression for a specific table.int
getDec()
Get the number of decimals of precision after the decimal point used for outputgetExpression(int index)
Get an expression for a given tableGet the list of expressions to be applied to each input table in order to compute the output values.getName()
Get the name of this columnint
getType()
Get the type of this column.Get the type string for this column, which may be C, I, N or L (String, Integer, Number, Boolean).int
getWidth()
Get the width of this column used for output
-
Constructor Details
-
AppendColumnSpec
Create a column definition.- Parameters:
name
- the name to be used for the columntype
- the data type, which may be C, I, N or L (String, Integer, Number, Boolean)width
- the field width to be used on outputdec
- the number of digits of precision after the decimal place, used on output
-
AppendColumnSpec
Create a column definition.- Parameters:
name
- the name to be used for the columntype
- the data type, as taken from theAttributeFormat
class. Valid types are INTEGER, NUMBER, BOOLEAN and STRING.width
- the field width to be used on outputdec
- the number of digits of precision after the decimal place, used on output
-
-
Method Details
-
getExpressions
Get the list of expressions to be applied to each input table in order to compute the output values. -
addExpression
Add an expression for a specific table. THe expressions must initially be added in order. -
getExpression
Get an expression for a given table -
getName
Get the name of this column -
getType
public int getType()Get the type of this column. The types are as defined in the AttributeFormat class (INTEGER, NUMBER, STRING, BOOLEAN) -
getTypeString
Get the type string for this column, which may be C, I, N or L (String, Integer, Number, Boolean). -
getWidth
public int getWidth()Get the width of this column used for output -
getDec
public int getDec()Get the number of decimals of precision after the decimal point used for output
-