org.carrot2.core
Class ProcessingComponentDescriptor

java.lang.Object
  extended by org.carrot2.core.ProcessingComponentDescriptor
Direct Known Subclasses:
DocumentSourceDescriptor

public class ProcessingComponentDescriptor
extends Object

Descriptor of a IProcessingComponent being part of a ProcessingComponentSuite.


Nested Class Summary
static class ProcessingComponentDescriptor.ProcessingComponentDescriptorToId
          Transforms a ProcessingComponentDescriptor to its identifier.
 
Method Summary
 String getAttributeSetId()
           
 AttributeValueSets getAttributeSets()
           
 String getAttributeSetsResource()
           
 BindableDescriptor getBindableDescriptor()
          Builds and returns a BindableDescriptor for an instance of this descriptor's IProcessingComponent, with default Init attributes initialized with the default attribute set.
 Class<? extends IProcessingComponent> getComponentClass()
           
 ProcessingComponentConfiguration getComponentConfiguration()
           
 String getDescription()
           
 String getIconPath()
           
 String getId()
           
 Throwable getInitializationFailure()
          Returns initialization failure (Throwable) or null.
 String getLabel()
           
 String getMnemonic()
           
 String getTitle()
           
 boolean isComponentAvailable()
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Method Detail

getComponentConfiguration

public ProcessingComponentConfiguration getComponentConfiguration()

getComponentClass

public Class<? extends IProcessingComponent> getComponentClass()
Returns:
Returns the Class object for this component.
Throws:
RuntimeException - if the class cannot be defined for some reason (class loader issues).

getId

public String getId()

getLabel

public String getLabel()

getMnemonic

public String getMnemonic()

getTitle

public String getTitle()

getIconPath

public String getIconPath()
Returns:
Returns (optional) path to the icon of this component. The interpretation of this path is up to the application (icon resources may be placed in various places).

getDescription

public String getDescription()

getAttributeSetsResource

public String getAttributeSetsResource()
Returns:
Return the name of a resource from which getAttributeSets() were read or null if there was no such resource.

getAttributeSets

public AttributeValueSets getAttributeSets()

getAttributeSetId

public String getAttributeSetId()

getBindableDescriptor

public BindableDescriptor getBindableDescriptor()
Builds and returns a BindableDescriptor for an instance of this descriptor's IProcessingComponent, with default Init attributes initialized with the default attribute set. If the default attribute set does not provide values for some required Bindable Init attributes, the returned descriptor may be incomplete.


isComponentAvailable

public boolean isComponentAvailable()
Returns:
Return true if instances of this descriptor are available (class can be resolved, instances can be created).

getInitializationFailure

public Throwable getInitializationFailure()
Returns initialization failure (Throwable) or null.


toString

public String toString()
Overrides:
toString in class Object


Copyright (c) Dawid Weiss, Stanislaw Osinski