public class SimplePrecondition_impl extends MetaDataObject_impl implements SimplePrecondition
SimplePrecondition
.MetaDataObject_impl.MetaDataAttr, MetaDataObject_impl.SerialContext, MetaDataObject_impl.Serializer
serialContext
ELEMENT_OF, EQUAL, LANGUAGE_SUBSUMED, PRECONDITION_TYPE
Constructor and Description |
---|
SimplePrecondition_impl() |
Modifier and Type | Method and Description |
---|---|
boolean |
evaluate(CAS aCAS)
Determines if this precondition is satisfied by a CAS.
|
Object |
getComparisonValue()
Retrieves the literal value to which features' values will be compared.
|
boolean |
getDefault()
Retrieves the default value for this precondition.
|
String |
getFeatureName()
Gets the name of the feature to be tested.
|
String |
getFsIndexName()
Retrieves the name of the FeatureStructure index containing FeatureStructures to be tested by
this precondition.
|
FSMatchConstraint |
getFsMatchConstraint()
Retrieves the FSMatchConstraint that determines which CAS feature structures will be tested by
this precondition.
|
String |
getPreconditionType()
Gets the type of this precondition.
|
String |
getPredicate()
Retrieves the predicate used to compare the test value to the comparison value.
|
protected XmlizationInfo |
getXmlizationInfo()
To be implemented by subclasses to return information describing how to represent this object
in XML.
|
protected static boolean |
isValidPredicateName(Object aName)
Determines whether the given String is a valid name a predicate defined by this class.
|
void |
setComparisonValue(Object aValue)
Sets the literal value to which features' values will be compared.
|
void |
setDefault(boolean aDefault)
Sets the default value for this precondition.
|
void |
setFeatureName(String aFeatureName)
Sets the name of the feature to be tested.
|
void |
setFsIndexName(String aIndexName)
Sets the name of the FeatureStructure index containing FeatureStructures to be tested by this
precondition.
|
void |
setFsMatchConstraint(FSMatchConstraint aConstraint)
Sets the FSMatchConstraint that determines which CAS feature structures will be tested by this
precondition.
|
void |
setPredicate(String aPredicate)
Sets the predicate used to compare the test value to the comparison value.
|
buildFromXMLElement, buildFromXMLElement, clone, equals, getAdditionalAttributes, getAttributeClass, getAttributeValue, getInfoset, getMatchingNode, getPropertyDescriptors, getPropertyXmlInfo, getRelativePathBase, getSerialContext, getSourceUrl, getSourceUrlString, getWrapperClass, getXMLAttributes, hashCode, isModifiable, listAttributes, readArrayPropertyValueFromXMLElement, readMapPropertyFromXml, readPropertyValueFromXMLElement, readUnknownPropertyValueFromXMLElement, resolveSettings, setAttributeValue, setInfoset, setSourceUrl, setSourceUrlIfNull, toString, toXML, toXML, toXML, toXML, valueIsNullOrEmptyArray, writeArrayPropertyAsElement, writeMapPropertyToXml, writePropertyAsElement
finalize, getClass, notify, notifyAll, wait, wait, wait
clone, equals, getAttributeValue, getSourceUrl, getSourceUrlString, isModifiable, listAttributes, setAttributeValue, setSourceUrl
buildFromXMLElement, buildFromXMLElement, toXML, toXML, toXML, toXML
public String getPreconditionType()
SimplePrecondition
Precondition
has its own
standard type identifier String. These identifier Strings are used instead of Java class names
in order to ease portability of metadata to other languages.getPreconditionType
in interface Precondition
getPreconditionType
in interface SimplePrecondition
SimplePrecondition.PRECONDITION_TYPE
Precondition.getPreconditionType()
public boolean getDefault()
SimplePrecondition
getDefault
in interface SimplePrecondition
SimplePrecondition.getDefault()
public String getFeatureName()
SimplePrecondition
getFeatureName
in interface SimplePrecondition
null
if noneSimplePrecondition.getFeatureName()
public String getFsIndexName()
SimplePrecondition
getFsIndexName
in interface SimplePrecondition
null
if the default annotation index should be
usedSimplePrecondition.getFsIndexName()
public FSMatchConstraint getFsMatchConstraint()
SimplePrecondition
getFsMatchConstraint
in interface SimplePrecondition
null
if noneSimplePrecondition.getFsMatchConstraint()
public void setDefault(boolean aDefault)
SimplePrecondition
setDefault
in interface SimplePrecondition
aDefault
- the default valueSimplePrecondition.setDefault(boolean)
public void setFeatureName(String aFeatureName)
SimplePrecondition
setFeatureName
in interface SimplePrecondition
aFeatureName
- the feature name, null
if noneSimplePrecondition.setFeatureName(java.lang.String)
public void setFsIndexName(String aIndexName)
SimplePrecondition
setFsIndexName
in interface SimplePrecondition
aIndexName
- the name of the FS index, null
if the default annotation index should be
usedSimplePrecondition.setFsIndexName(java.lang.String)
public void setFsMatchConstraint(FSMatchConstraint aConstraint)
SimplePrecondition
setFsMatchConstraint
in interface SimplePrecondition
aConstraint
- the FS match constraint, null
if noneSimplePrecondition.setFsMatchConstraint(org.apache.uima.cas.FSMatchConstraint)
public boolean evaluate(CAS aCAS)
Precondition
evaluate
in interface Precondition
aCAS
- the CAS against which to evaluate this preconditionPrecondition.evaluate(org.apache.uima.cas.CAS)
public Object getComparisonValue()
SimplePrecondition
getComparisonValue
in interface SimplePrecondition
SimplePrecondition.getComparisonValue()
public void setComparisonValue(Object aValue)
SimplePrecondition
setComparisonValue
in interface SimplePrecondition
aValue
- the comparison value, which must be a String, Integer, Float, Boolean, or an array of
one of those four types.SimplePrecondition.setComparisonValue(Object)
public String getPredicate()
SimplePrecondition
getPredicate
in interface SimplePrecondition
SimplePrecondition.getPredicate()
public void setPredicate(String aPredicate)
SimplePrecondition
setPredicate
in interface SimplePrecondition
aPredicate
- a String that identifies the predicate used. This must match one of the constants
defined on this interface.SimplePrecondition.setPredicate(String)
protected static boolean isValidPredicateName(Object aName)
setPredicate(String)
method, and are
defined by constants on the SimplePrecondition
interface.aName
- an Object to testaName
is a String
that is a valid
predicate name.protected XmlizationInfo getXmlizationInfo()
MetaDataObject_impl
getXmlizationInfo
in class MetaDataObject_impl
Copyright © 2006–2022 The Apache Software Foundation. All rights reserved.