public abstract class AbstractPluginDescriptor extends java.lang.Object implements PluginDescriptor
Constructor and Description |
---|
AbstractPluginDescriptor() |
Modifier and Type | Method and Description |
---|---|
protected abstract java.lang.Object[] |
execute(PluginContext context,
int methodIndex,
java.lang.Object... allArgs)
In this method, the pluginDescriptor should do the actual work of
concstructing the result.
|
PluginExecutionResult |
invoke(int methodIndex,
PluginContext context,
java.lang.Object... args)
Asynchronously invokes a method of this plugin.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
compareTo, equals, getAnnotation, getAnnotation, getCategories, getContextType, getHelp, getIcon, getID, getIndexInMethod, getIndexInParameterNames, getKeywords, getMethodHelp, getMethodLabel, getMostSignificantResult, getName, getNumberOfMethods, getPackage, getParameterNames, getParameterNames, getParameterTypes, getParameterTypes, getPluginParameterName, getPluginParameterType, getReturnNames, getReturnTypes, getTypesAtParameterIndex, getURL, handlesCancel, hasAnnotation, hasAnnotation, hashCode, isUserAccessible, meetsLevelThreshold, meetsQualityThreshold, toString
public PluginExecutionResult invoke(int methodIndex, PluginContext context, java.lang.Object... args)
PluginDescriptor
context.getParentContext().getPluginLifeCycleEventListeners().firePluginCreated(context);
invoke
in interface PluginDescriptor
methodIndex
- The index of the method to be invokedcontext
- the context in which this plugin should be invoked. The plugin
may assume that this context is meant only for its execution.args
- the objects to be passed to the plugin. These objects should
be in the right order. However, if ProMFuture
objects are provided, the plugin will synchronize on them.
This syncrhonization is performed in a fast-fail fashion, i.e.
the first future that results in an exception during execution
will result in an exception while invoking this plugin. This
exception is caught and the context is signaled about it.protected abstract java.lang.Object[] execute(PluginContext context, int methodIndex, java.lang.Object... allArgs) throws java.lang.Exception
context
- methodIndex
- allArgs
- java.lang.Exception