Class Description
- java.lang.Object
-
- de.julielab.jcore.pipeline.builder.base.main.Description
-
- All Implemented Interfaces:
Serializable,Cloneable
public class Description extends Object implements Serializable, Cloneable
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description Description()Required for JSON deserialization and tests.Description(URL sourceUrl)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddCapability(String type, String value)Descriptionclone()booleanequals(Object o)List<String>getCapabilities(String type)Returns the input or output capabilities as specified in the underlying UIMA descriptor of this description.PipelineBuilderConstants.JcoreMeta.CategorygetCategory()Map<String,org.apache.uima.resource.metadata.ConfigurationParameter>getConfigurationParameters()ObjectgetConfigurationParameterValue(String parameter)org.apache.uima.resource.metadata.MetaDataObjectgetDescriptor()org.apache.uima.analysis_engine.AnalysisEngineDescriptiongetDescriptorAsAnalysisEngineDescription()org.apache.uima.collection.CollectionReaderDescriptiongetDescriptorAsCollectionReaderDescription()org.apache.uima.flow.FlowControllerDescriptiongetDescriptorAsFlowControllerDescriptor()StringgetDescriptorType()List<String>getInputCapabilities()StringgetLocation()MetaDescriptiongetMetaDescription()StringgetName()List<String>getOutputCapabilities()StringgetUimaDescPath()This field is set when the owningJCoReUIMAPipelineis stored.URIgetUri()StringgetXmlName()inthashCode()booleanisActive()Returns whether this component is active.voidsetActive(boolean active)voidsetCapabilities(String type, List<String> values)voidsetCategory(PipelineBuilderConstants.JcoreMeta.Category category)voidsetConfigurationParameterValue(String key, Object value)voidsetDescriptor(org.apache.uima.resource.metadata.MetaDataObject descriptor)voidsetLocation(String location)voidsetMetaDescription(MetaDescription metaDescription)voidsetName(String name)voidsetUimaDescPath(String uimaDescPath)voidsetUri(URI uri)voidsetXmlName(String xmlName)StringtoString()
-
-
-
Constructor Detail
-
Description
public Description()
Required for JSON deserialization and tests.
-
Description
public Description(URL sourceUrl) throws URISyntaxException, IOException, org.apache.uima.util.InvalidXMLException
- Throws:
URISyntaxExceptionIOExceptionorg.apache.uima.util.InvalidXMLException
-
-
Method Detail
-
isActive
public boolean isActive()
Returns whether this component is active. Non-active components are not stored in the pipeline desc/ directory and also not included in the CPE.xml.- Returns:
- true, if this component is active, false otherwise.
-
setActive
public void setActive(boolean active)
- Parameters:
active-- See Also:
isActive
-
getUimaDescPath
public String getUimaDescPath()
This field is set when the owningJCoReUIMAPipelineis stored. The value of this field is the path to the UIMA descriptor associated with this Description relative to the pipeline desc/ directory. It may be null if the descriptor is not stored by itself but rather in an AAE.- Returns:
- The path to the UIMA descriptor, relative to desc/.
-
setUimaDescPath
public void setUimaDescPath(String uimaDescPath)
-
getUri
public URI getUri()
- Returns:
- The URI of the original UIMA descriptor within a JAR.
-
setUri
public void setUri(URI uri)
-
getLocation
public String getLocation()
- Returns:
- The value of the 'location' property in the component.meta file of the component. This is the classpath resource address of the component UIMA descriptor.
-
setLocation
public void setLocation(String location)
-
getCategory
public PipelineBuilderConstants.JcoreMeta.Category getCategory()
-
setCategory
public void setCategory(PipelineBuilderConstants.JcoreMeta.Category category)
-
getDescriptorType
public String getDescriptorType()
-
getXmlName
public String getXmlName()
-
setXmlName
public void setXmlName(String xmlName)
-
getCapabilities
public List<String> getCapabilities(String type)
Returns the input or output capabilities as specified in the underlying UIMA descriptor of this description.
- Parameters:
type- The type of capabilities to return, i.e.PipelineBuilderConstants.Descriptor.CAPABILITIES_INorPipelineBuilderConstants.Descriptor.CAPABILITIES_OUT-- Returns:
- The requested UIMA type capabilities.
-
getName
public String getName()
-
setName
public void setName(String name)
-
getConfigurationParameters
public Map<String,org.apache.uima.resource.metadata.ConfigurationParameter> getConfigurationParameters()
-
setConfigurationParameterValue
public void setConfigurationParameterValue(String key, Object value)
-
getDescriptor
public org.apache.uima.resource.metadata.MetaDataObject getDescriptor()
-
setDescriptor
public void setDescriptor(org.apache.uima.resource.metadata.MetaDataObject descriptor)
-
getDescriptorAsCollectionReaderDescription
public org.apache.uima.collection.CollectionReaderDescription getDescriptorAsCollectionReaderDescription()
-
getDescriptorAsAnalysisEngineDescription
public org.apache.uima.analysis_engine.AnalysisEngineDescription getDescriptorAsAnalysisEngineDescription()
-
getDescriptorAsFlowControllerDescriptor
public org.apache.uima.flow.FlowControllerDescription getDescriptorAsFlowControllerDescriptor()
-
getMetaDescription
public MetaDescription getMetaDescription()
-
setMetaDescription
public void setMetaDescription(MetaDescription metaDescription)
-
clone
public Description clone() throws CloneNotSupportedException
- Overrides:
clonein classObject- Throws:
CloneNotSupportedException
-
-