public class Capability_impl extends MetaDataObject_impl implements Capability
Capability
MetaDataObject_impl.MetaDataAttr, MetaDataObject_impl.SerialContext, MetaDataObject_impl.Serializer
serialContext
EMPTY_CAPABILITIES
Constructor and Description |
---|
Capability_impl() |
Modifier and Type | Method and Description |
---|---|
void |
addInputFeature(String aFeatureName)
A convenience method that adds an input Feature to this Capability.
|
void |
addInputSofa(String aSofaName)
A convenience method that adds an input Sofa name to this Capability.
|
void |
addInputType(String aTypeName,
boolean aAllAnnotatorFeatures)
A convenience method that adds an input Type to this Capability.
|
void |
addOutputFeature(String aFeatureName)
A convenience method that adds an output Feature to this Capability.
|
void |
addOutputSofa(String aSofaName)
A convenience method that adds an output Sofa name to this Capability.
|
void |
addOutputType(String aTypeName,
boolean aAllAnnotatorFeatures)
A convenience method that adds an output Type to this Capability.
|
void |
addSupportedLanguage(String aLanguage)
A convenience method that adds a supported language to this Capability.
|
String |
getDescription()
Gets the description of this Capability.
|
TypeOrFeature[] |
getInputs()
Gets the inputs of this Capability.
|
String[] |
getInputSofas()
Gets the inputs Sofa names of this Capability.
|
String[] |
getLanguagesSupported()
A convenience method that analyzes the preconditions of this
Capability and
returns the ISO language identifiers that the Resource supports. |
String[] |
getMimeTypesSupported()
A convenience method that analyzes the preconditions of this
Capability and
returns the MIME types that the Resource can take as input. |
TypeOrFeature[] |
getOutputs()
Gets the outputs of this Capability.
|
String[] |
getOutputSofas()
Gets the output Sofa names of this Capability.
|
Precondition[] |
getPreconditions()
Retrieves the preconditions that must be satisfied in order for the Resource to begin
processing.
|
protected XmlizationInfo |
getXmlizationInfo()
To be implemented by subclasses to return information describing how to represent this object
in XML.
|
void |
removeSupportedLanguage(String aLanguage)
A convenience method that removes a supported language from this Capability.
|
void |
setDescription(String aDescription)
Sets the description of this Capability.
|
void |
setInputs(TypeOrFeature[] aInputs)
Sets the inputs of this Capability.
|
void |
setInputSofas(String[] aInputSofaNames)
Sets the input Sofa names.
|
void |
setLanguagesSupported(String[] aLanguageIDs)
A convenience method that sets the languages that this Resource supports.
|
void |
setMimeTypesSupported(String[] aMimeTypes)
A convenience method that sets the MIME types that this Resource can take as input.
|
void |
setOutputs(TypeOrFeature[] aOutputs)
Sets the outputs of this Capability.
|
void |
setOutputSofas(String[] aOutputSofaNames)
Sets the output Sofa names of this capability
|
void |
setPreconditions(Precondition[] aPreconditions)
Sets the
Precondition s of this Capability . |
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 getDescription()
Capability
getDescription
in interface Capability
public void setDescription(String aDescription)
Capability
setDescription
in interface Capability
aDescription
- aDescription the description of this Capability.public TypeOrFeature[] getInputs()
Capability
getInputs
in interface Capability
Capability.getInputs()
public TypeOrFeature[] getOutputs()
Capability
getOutputs
in interface Capability
Capability.getOutputs()
public Precondition[] getPreconditions()
Capability
getPreconditions
in interface Capability
Precondition
s.Capability.getPreconditions()
public String[] getLanguagesSupported()
Capability
Capability
and
returns the ISO language identifiers that the Resource supports. This is only meaningful when
analyzing text documents.getLanguagesSupported
in interface Capability
Capability.getLanguagesSupported()
public String[] getMimeTypesSupported()
Capability
Capability
and
returns the MIME types that the Resource can take as input.getMimeTypesSupported
in interface Capability
Capability.getMimeTypesSupported()
public void setInputs(TypeOrFeature[] aInputs)
Capability
setInputs
in interface Capability
aInputs
- an array of references to Types or Features in this Resource's TypeSystem.Capability.setInputs(TypeOrFeature[])
public void setOutputs(TypeOrFeature[] aOutputs)
Capability
setOutputs
in interface Capability
aOutputs
- an array of references to Types or Features in this Resource's TypeSystem.Capability.setOutputs(TypeOrFeature[])
public void setPreconditions(Precondition[] aPreconditions)
Capability
Precondition
s of this Capability
.setPreconditions
in interface Capability
aPreconditions
- an array of Precondition
objectsCapability.setPreconditions(Precondition[])
public void setLanguagesSupported(String[] aLanguageIDs)
Capability
Calling this method affects the preconditions of this Capability
. All other
language support preconditions will be removed, but non-language related preconditions will be
unaffected.
setLanguagesSupported
in interface Capability
aLanguageIDs
- an array of ISO language identifiers. An empty array means that the Resource claims to
be language-independent.Capability.setLanguagesSupported(String[])
public void setMimeTypesSupported(String[] aMimeTypes)
Capability
Calling this method affects the preconditions of this Capability
. All other
MIME type preconditions will be removed, but other preconditions will be unaffected.
setMimeTypesSupported
in interface Capability
aMimeTypes
- an array of MIME types. This may be empty if the Resource does not declare MIME type
preconditions.Capability.setMimeTypesSupported(java.lang.String[])
public void addInputType(String aTypeName, boolean aAllAnnotatorFeatures)
Capability
addInputType
in interface Capability
aTypeName
- the fully qualified type nameaAllAnnotatorFeatures
- if true, indicates that this Capability requires as input all features of this type
that are specified in the same AnalysisEngine descriptor. If false, features must be
explicitly declared by calling Capability.addInputFeature(String)
.Capability.addInputType(java.lang.String,
boolean)
public void addInputFeature(String aFeatureName)
Capability
addInputFeature
in interface Capability
aFeatureName
- the fully qualified feature nameCapability.addInputFeature(java.lang.String)
public void addOutputType(String aTypeName, boolean aAllAnnotatorFeatures)
Capability
addOutputType
in interface Capability
aTypeName
- the fully qualified type nameaAllAnnotatorFeatures
- if true, indicates that this Capability declares as output all features of this type
that are specified in the same AnalysisEngine descriptor. If false, features must be
explicitly declared by calling Capability.addOutputFeature(String)
.Capability.addOutputType(java.lang.String,
boolean)
public void addOutputFeature(String aFeatureName)
Capability
addOutputFeature
in interface Capability
aFeatureName
- the fully qualified feature nameCapability.addOutputFeature(java.lang.String)
public void addSupportedLanguage(String aLanguage)
Capability
addSupportedLanguage
in interface Capability
aLanguage
- the ISO language identifierCapability.addSupportedLanguage(java.lang.String)
public void removeSupportedLanguage(String aLanguage)
Capability
removeSupportedLanguage
in interface Capability
aLanguage
- the ISO language identifierpublic String[] getInputSofas()
Capability
getInputSofas
in interface Capability
public String[] getOutputSofas()
Capability
getOutputSofas
in interface Capability
public void setInputSofas(String[] aInputSofaNames)
Capability
setInputSofas
in interface Capability
aInputSofaNames
- an array of strings containing SofA namespublic void setOutputSofas(String[] aOutputSofaNames)
Capability
setOutputSofas
in interface Capability
aOutputSofaNames
- an array of strings containing SoFA namepublic void addInputSofa(String aSofaName)
Capability
addInputSofa
in interface Capability
aSofaName
- the sofa to add to the inputspublic void addOutputSofa(String aSofaName)
Capability
addOutputSofa
in interface Capability
aSofaName
- the sofa to add as an outputprotected XmlizationInfo getXmlizationInfo()
MetaDataObject_impl
getXmlizationInfo
in class MetaDataObject_impl
Copyright © 2006–2021 The Apache Software Foundation. All rights reserved.