ABLE 2.0.0 07/02/2003 10:25:01

com.ibm.able.data
Interface AbleField

All Known Implementing Classes:
AbleGenericField, AbleContinuousField, AbleCategoricalField, AbleDiscreteField

public interface AbleField

AbleField defines a basic field for use in data sources and inferencing. Fields have a known name or label, a column or index in a sequence of fields that constitute a record, and understand the range and restrictions of its values.


Method Summary
 void computeStatistics(java.lang.Object inValue)
          Compute statistics as appropriate for the field data type.
 int getColumn()
          Get the column index position of this field in a record.
 java.lang.String getDataTypeString()
          Get the data type of this field as a string - "continuous" for example.
 AbleTranslateTemplate getInputTranslateTemplate()
          Provide an input translate template for this field.
 java.util.Map getMap()
          Get the Map of all unique values that are possible for this field.
 java.lang.String getName()
          Return the field name.
 int getNormalizedSize()
          Get the expanded representation of this field.
 double getNumericValue(java.lang.Object inValue)
          Get the value of this field as a double.
 AbleTranslateTemplate getOutputTranslateTemplate()
          Provide an output translate template for this field.
 java.lang.String getStringValue()
          Return the value of this field, represented as a string for display.
 int getUsage()
          Get the usage type of this field - "input" for example.
 java.lang.String getUsageString()
          Get the usage type of this field as a string - "input" for example.
 void setColumn(int col)
          Set the index position in the record, based on field definition order.
 void setUsage(java.lang.String usage)
          Set the usage type of this from a string - "input" for example.
 

Method Detail

getName

public java.lang.String getName()
Return the field name.

getInputTranslateTemplate

public AbleTranslateTemplate getInputTranslateTemplate()
Provide an input translate template for this field. Typically this is used to normalize or convert values for algorithms such as neural networks.

getOutputTranslateTemplate

public AbleTranslateTemplate getOutputTranslateTemplate()
Provide an output translate template for this field. Typically this is used to normalize or convert values for algorithms such as neural networks.

getDataTypeString

public java.lang.String getDataTypeString()
Get the data type of this field as a string - "continuous" for example. Data types are listed in AbleData.DataType(int).

getUsageString

public java.lang.String getUsageString()
Get the usage type of this field as a string - "input" for example. Usage types are listed in AbleData.UsageType(java.lang.String).

getUsage

public int getUsage()
Get the usage type of this field - "input" for example. Usage types are listed in AbleData.UsageType(java.lang.String).

setUsage

public void setUsage(java.lang.String usage)
Set the usage type of this from a string - "input" for example. Usage types are listed in AbleData.UsageType(java.lang.String).

getStringValue

public java.lang.String getStringValue()
                                throws AbleDataException
Return the value of this field, represented as a string for display.

setColumn

public void setColumn(int col)
Set the index position in the record, based on field definition order.

getColumn

public int getColumn()
Get the column index position of this field in a record.

computeStatistics

public void computeStatistics(java.lang.Object inValue)
Compute statistics as appropriate for the field data type. For example, continuous fields compute min/max/mean. Categorical and discrete fields use this to add a new legal value to their dictionary.

getNumericValue

public double getNumericValue(java.lang.Object inValue)
Get the value of this field as a double. Non-numeric fields such as AbleCategoricalField would typically return a numeric index into the dictionary of allowed values. Some implementations might return Double.NaN.

getNormalizedSize

public int getNormalizedSize()
Get the expanded representation of this field. For example, an AbleCategoricalField or AbleDiscreteField would return the number of dictionary entries.

getMap

public java.util.Map getMap()
Get the Map of all unique values that are possible for this field. The Map's key should be a string representation of an integer, and the object should be the value itself. Fields which do not have a unique number of values should return null.

ABLE 2.0.0 07/02/2003 10:25:01

(C) Copyright IBM Corporation 1999, 2003