MaltParser 1.5.2

org.maltparser.core.symbol
Class TableFeature

java.lang.Object
  extended by org.maltparser.core.symbol.TableFeature
All Implemented Interfaces:
FeatureFunction, Function, Modifiable
Direct Known Subclasses:
InputTableFeature, OutputTableFeature

public abstract class TableFeature
extends Object
implements FeatureFunction, Modifiable


Field Summary
protected  SingleFeatureValue featureValue
           
protected  SymbolTable table
           
protected  SymbolTableHandler tableHandler
           
protected  String tableName
           
protected  int type
           
 
Constructor Summary
TableFeature()
           
 
Method Summary
 boolean equals(Object obj)
           
 int getCode(String value)
          Returns the integer representation of the string symbol according to the feature function.
 FeatureValue getFeatureValue()
          Returns the feature value
 String getMapIdentifier()
           
abstract  Class<?>[] getParameterTypes()
          Returns an array of class types used by the feature extraction system to invoke initialize with correct arguments.
 String getSymbol(int value)
          Returns the string representation of the integer code according to the feature function.
 SymbolTable getSymbolTable()
          Returns the symbol table used by the feature function.
 SymbolTableHandler getTableHandler()
           
 String getTableName()
           
 int getType()
           
abstract  void initialize(Object[] arguments)
          Initialize the feature function
 void setFeatureValue(int indexCode)
          Override the feature value of the feature function.
 void setFeatureValue(String symbol)
          Override the feature value of the feature function.
 void setSymbolTable(SymbolTable table)
           
 void setTableHandler(SymbolTableHandler tableHandler)
           
 void setTableName(String name)
           
 void setType(int type)
           
 String toString()
           
abstract  void update()
          Cause the feature function to update the feature value.
 void updateCardinality()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

featureValue

protected SingleFeatureValue featureValue

table

protected SymbolTable table

tableName

protected String tableName

tableHandler

protected SymbolTableHandler tableHandler

type

protected int type
Constructor Detail

TableFeature

public TableFeature()
             throws MaltChainedException
Throws:
MaltChainedException
Method Detail

update

public abstract void update()
                     throws MaltChainedException
Description copied from interface: Function
Cause the feature function to update the feature value.

Specified by:
update in interface Function
Throws:
MaltChainedException

initialize

public abstract void initialize(Object[] arguments)
                         throws MaltChainedException
Description copied from interface: Function
Initialize the feature function

Specified by:
initialize in interface Function
Parameters:
arguments - an array of arguments with the type returned by getParameterTypes()
Throws:
MaltChainedException

getParameterTypes

public abstract Class<?>[] getParameterTypes()
Description copied from interface: Function
Returns an array of class types used by the feature extraction system to invoke initialize with correct arguments.

Specified by:
getParameterTypes in interface Function
Returns:
an array of class types

getSymbol

public String getSymbol(int value)
                 throws MaltChainedException
Description copied from interface: FeatureFunction
Returns the string representation of the integer code according to the feature function.

Specified by:
getSymbol in interface FeatureFunction
Parameters:
value - the integer representation of the symbol
Returns:
the string representation of the integer code according to the feature function.
Throws:
MaltChainedException

getCode

public int getCode(String value)
            throws MaltChainedException
Description copied from interface: FeatureFunction
Returns the integer representation of the string symbol according to the feature function.

Specified by:
getCode in interface FeatureFunction
Parameters:
value - the string representation of the symbol
Returns:
the integer representation of the string symbol according to the feature function.
Throws:
MaltChainedException

getSymbolTable

public SymbolTable getSymbolTable()
Description copied from interface: FeatureFunction
Returns the symbol table used by the feature function.

Specified by:
getSymbolTable in interface FeatureFunction
Returns:
the symbol table used by the feature function.

setSymbolTable

public void setSymbolTable(SymbolTable table)

updateCardinality

public void updateCardinality()

setFeatureValue

public void setFeatureValue(int indexCode)
                     throws MaltChainedException
Description copied from interface: Modifiable
Override the feature value of the feature function.

Specified by:
setFeatureValue in interface Modifiable
Parameters:
indexCode - an integer representation of the symbol
Throws:
MaltChainedException

setFeatureValue

public void setFeatureValue(String symbol)
                     throws MaltChainedException
Description copied from interface: Modifiable
Override the feature value of the feature function.

Specified by:
setFeatureValue in interface Modifiable
Parameters:
symbol - an string representation of the symbol
Throws:
MaltChainedException

getFeatureValue

public FeatureValue getFeatureValue()
Description copied from interface: FeatureFunction
Returns the feature value

Specified by:
getFeatureValue in interface FeatureFunction
Returns:
the feature value

getTableHandler

public SymbolTableHandler getTableHandler()

setTableHandler

public void setTableHandler(SymbolTableHandler tableHandler)

equals

public boolean equals(Object obj)
Overrides:
equals in class Object

setTableName

public void setTableName(String name)

getTableName

public String getTableName()

getType

public int getType()
Specified by:
getType in interface FeatureFunction

setType

public void setType(int type)

getMapIdentifier

public String getMapIdentifier()
Specified by:
getMapIdentifier in interface FeatureFunction

toString

public String toString()
Overrides:
toString in class Object

MaltParser 1.5.2

Copyright 2007-2011 Johan Hall, Jens Nilsson and Joakim Nivre.