Overview | Package | Class | Use | Tree | Serialized | Deprecated | Index | Help
| ABLE 2.3.0 07/13/2005 14:21:00
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.ibm.able.data
Interface AbleField

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

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.

  Throws:
    `AbleDataException`

### 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.

Overview | Package | Class | Use | Tree | Serialized | Deprecated | Index | Help
| ABLE 2.3.0 07/13/2005 14:21:00
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

(C) Copyright IBM Corporation 1999, 2005