org.apache.uima.cas_data.impl
Class FeatureStructureImpl

java.lang.Object
  extended by org.apache.uima.cas_data.impl.FeatureStructureImpl
All Implemented Interfaces:
java.io.Serializable, FeatureStructure
Direct Known Subclasses:
PrimitiveArrayFSImpl, ReferenceArrayFSImpl

public class FeatureStructureImpl
extends java.lang.Object
implements FeatureStructure

See Also:
Serialized Form

Constructor Summary
FeatureStructureImpl()
           
 
Method Summary
 java.lang.Object get()
           
 java.lang.String[] getFeatureNames()
          Gets the names of all features on this FeatureStructure.
 FeatureValue getFeatureValue(java.lang.String aFeatureName)
          Gets the value of a feature
 java.lang.String getId()
          Gets the ID of this FeatureStructure.
 int[] getIndexed()
          Gets the index repositories that this FeatureStrucutre should be indexed in if the CasData is converted to a CAS Object.
 java.lang.String getType()
          Gets the type of this FeatureStructure
 boolean isIndexed()
          Deprecated.  
 void setFeatureValue(java.lang.String aFeatureType, FeatureValue aValue)
          Sets the value of a feature
 void setId(java.lang.String string)
          Sets the ID of this FeatureStructure.
 void setIndexed(boolean b)
          Deprecated.  
 void setIndexed(int[] aIndexed)
          Sets the index repositories that this FeatureStrucutre should be indexed in if the CasData is converted to a CAS Object.
 void setType(java.lang.String aType)
          Sets the type of this FeatureStructure
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

FeatureStructureImpl

public FeatureStructureImpl()
Method Detail

getType

public java.lang.String getType()
Description copied from interface: FeatureStructure
Gets the type of this FeatureStructure

Specified by:
getType in interface FeatureStructure
Returns:
this FeatureStructure's type, as a string

setType

public void setType(java.lang.String aType)
Description copied from interface: FeatureStructure
Sets the type of this FeatureStructure

Specified by:
setType in interface FeatureStructure
Parameters:
aType - this FeatureStructure's type, as a string

getFeatureNames

public java.lang.String[] getFeatureNames()
Description copied from interface: FeatureStructure
Gets the names of all features on this FeatureStructure.

Specified by:
getFeatureNames in interface FeatureStructure
Returns:
an array of feature names

getFeatureValue

public FeatureValue getFeatureValue(java.lang.String aFeatureName)
Description copied from interface: FeatureStructure
Gets the value of a feature

Specified by:
getFeatureValue in interface FeatureStructure
Parameters:
aFeatureName - name of feature
Returns:
value of feature named aName, or null if there is no such feature

setFeatureValue

public void setFeatureValue(java.lang.String aFeatureType,
                            FeatureValue aValue)
Description copied from interface: FeatureStructure
Sets the value of a feature

Specified by:
setFeatureValue in interface FeatureStructure
Parameters:
aFeatureType - name of feature to set
aValue - value of feature

get

public java.lang.Object get()

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

getId

public java.lang.String getId()
Description copied from interface: FeatureStructure
Gets the ID of this FeatureStructure. IDs are optional, so this may return null. A FeatureStructure must have an ID if it is to be the target of a reference.

Specified by:
getId in interface FeatureStructure
Returns:

isIndexed

@Deprecated
public boolean isIndexed()
Deprecated. 

Description copied from interface: FeatureStructure
Gets whether this FeatureStructure should be indexed if the CasData is converted to a CAS Object. The CasData itself does not provide indexes.

Specified by:
isIndexed in interface FeatureStructure
Returns:

setId

public void setId(java.lang.String string)
Description copied from interface: FeatureStructure
Sets the ID of this FeatureStructure. IDs are optional, so null may be passed to this method. A FeatureStructure must have an ID if it is to be the target of a reference.

Specified by:
setId in interface FeatureStructure
Parameters:
string -

setIndexed

@Deprecated
public void setIndexed(boolean b)
Deprecated. 

Description copied from interface: FeatureStructure
Sets whether this FeatureStructure should be indexed if the CasData is converted to a CAS Object. The CasData itself does not provide indexes.

Specified by:
setIndexed in interface FeatureStructure
Parameters:
b -

getIndexed

public int[] getIndexed()
Description copied from interface: FeatureStructure
Gets the index repositories that this FeatureStrucutre should be indexed in if the CasData is converted to a CAS Object. The CasData itself does not provide indexes.

Specified by:
getIndexed in interface FeatureStructure
Returns:
an array containing the numbers of the index repsositories that should contain this FS. Returns an empty array if this FS is not indexed.

setIndexed

public void setIndexed(int[] aIndexed)
Description copied from interface: FeatureStructure
Sets the index repositories that this FeatureStrucutre should be indexed in if the CasData is converted to a CAS Object. The CasData itself does not provide indexes.

Specified by:
setIndexed in interface FeatureStructure
Parameters:
aIndexed - an array containing the numbers of the index repsositories that should contain this FS. Passing null is equivalent to passing an empty array.


Copyright © 2012. All Rights Reserved.