|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.embl.ebi.escience.scufl.Processor
public abstract class Processor
An abstract superclass of the various processor subtypes
| Field Summary |
|---|
| Fields inherited from interface org.embl.ebi.escience.scufl.IProcessor |
|---|
ENACTOR |
| Constructor Summary | |
|---|---|
Processor(ScuflModel model,
java.lang.String name)
Construct the processor with the given name and parent, complaining if the name doesn't conform to [a-zA-Z_0-9] |
|
| Method Summary | |
|---|---|
void |
addAlternate(AlternateProcessor ap)
Add an alternate processor to this processor definition |
void |
addAnnotationTemplate(AnnotationTemplate theTemplate)
Add an annotation template to this processor |
void |
addBreakpoint()
Add a breakpoint to the processor |
void |
addPort(Port the_port)
Add a new port to this processor |
AnnotationTemplate[] |
defaultAnnotationTemplates()
Create a standard annotation template for each pair of bound input / output ports, mostly just to test the metadata store and browser functionality. |
void |
fireModelEvent(ScuflModelEvent event)
Fire a change event back to the model |
AlternateProcessor[] |
getAlternatesArray()
Return the list of AlternateProcessor holders for this primary processor implementation. |
java.util.List |
getAlternatesList()
Return the alternates list object to allow addition or reordering of alternate processors |
AnnotationTemplate[] |
getAnnotationTemplates()
Return an array containing all annotation templates for this processor |
double |
getBackoff()
Return the factor by which the timeout value will be multiplied for each retry after the first. |
InputPort[] |
getBoundInputPorts()
Get an array of the input ports that are bound by data constraints defined within this processor |
OutputPort[] |
getBoundOutputPorts()
Get an array of all the output ports that are bound by data constraints and defined within this processor |
boolean |
getCritical()
Get whether the Processor is critical. |
int |
getDefaultWorkers()
Return the default number of workers for an instance of this processor type |
java.lang.String |
getDescription()
Get a description of the processor. |
InputPort[] |
getInputPorts()
Get an array containing only input ports |
IterationStrategy |
getIterationStrategy()
Get the iteration strategy for this processor, or null if the default should be used |
int |
getLogLevel()
Get the log level, this is the effective log level of the processor taking into account possible inheritence of the level from the ScuflModel instance. |
int |
getMaximumWorkers()
Return the maximum number of task implementations that should be launched for this processor. |
ScuflModel |
getModel()
Get the parent model |
java.lang.String |
getName()
Get the name for this processor. |
OutputPort[] |
getOutputPorts()
Get an array containing only output ports |
Port[] |
getPorts()
Get an array of the ports, input or output, defined within this processor. |
abstract java.util.Properties |
getProperties()
Return a properties object containing the processor specific properties for this processor type instance. |
int |
getRealLogLevel()
Get the real log level set by this processor, this can be -1 in which case the getLogLevel method will return the log level of the ScuflModel that 'owns' this processor |
java.lang.String |
getResourceHost()
If meaningful, obtain the host that the resource is based in. |
int |
getRetries()
Return the number of retries after the initial invocation attempt. |
int |
getRetryDelay()
Get the number of milliseconds to wait before first retrying an invocation of the task this processor represents. |
int |
getTimeout()
Return the time in milliseconds after which an instance of this processor should be regarded as having failed with a timeout. |
int |
getWorkers()
Return the number of workers for this instance |
boolean |
hasBreakpoint()
Check for a breakpoint |
boolean |
isBoring()
Is this processor boring? If so it shouldn't show up by default in the status display |
boolean |
isOffline()
Are we in offline mode? |
Port |
locatePort(java.lang.String port_name)
Find a particular named port |
Port |
locatePort(java.lang.String port_name,
boolean isInputPort)
Find a particular named port, input port if boolean flag is true |
void |
removeAlternate(AlternateProcessor ap)
Delete an alternate processor from this processor definition |
void |
removeAnnotationTemplate(AnnotationTemplate theTemplate)
Remove an annotation template from this processor |
void |
removePort(Port the_port)
Remove a port from a processor (only really applicable to the workflow source and sink ports, so be careful when you're using it) |
void |
rmvBreakpoint()
Remove a breakpoint to the processor |
void |
setBackoff(double backoff)
Set the backoff factor |
void |
setBoring(boolean boring)
Set whether this processor is boring |
void |
setCritical(boolean critical)
Set whether the Processor is critical. |
void |
setDescription(java.lang.String the_description)
Set the description for the processor. |
void |
setIterationStrategy(IterationStrategy i)
Set the iteration strategy |
void |
setLogLevel(int level)
Set the log level |
void |
setName(java.lang.String newName)
Set the name, providing that names doesn't exist within the current workflow that this processor is bound to. |
void |
setOffline()
|
void |
setOnline()
Allow subclasses to intercept requests to go offline and online, allows e.g. |
void |
setRetries(int retries)
Set the number of retries |
void |
setRetryDelay(int delay)
Set the retry delay |
void |
setTimeout(int timeout)
Set the timeout parameter |
void |
setWorkers(int workers)
Set the number of workers |
java.lang.String |
toString()
Return the processor's name in the toString() |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public Processor(ScuflModel model,
java.lang.String name)
throws ProcessorCreationException,
DuplicateProcessorNameException
ProcessorCreationException
DuplicateProcessorNameException| Method Detail |
|---|
public boolean isBoring()
isBoring in interface IProcessorpublic void setBoring(boolean boring)
setBoring in interface IProcessorpublic void setOnline()
setOnline in interface IProcessorpublic void setOffline()
setOffline in interface IProcessorpublic boolean hasBreakpoint()
hasBreakpoint in interface IProcessorpublic void addBreakpoint()
addBreakpoint in interface IProcessorpublic void rmvBreakpoint()
rmvBreakpoint in interface IProcessorpublic java.lang.String getResourceHost()
getResourceHost in interface IProcessorpublic int getMaximumWorkers()
getMaximumWorkers in interface IProcessorpublic int getDefaultWorkers()
getDefaultWorkers in interface IProcessorpublic final int getWorkers()
getWorkers in interface IProcessorpublic final void setWorkers(int workers)
setWorkers in interface IProcessorpublic void setName(java.lang.String newName)
setName in interface IProcessorpublic IterationStrategy getIterationStrategy()
getIterationStrategy in interface IProcessorpublic void setIterationStrategy(IterationStrategy i)
setIterationStrategy in interface IProcessorpublic AnnotationTemplate[] getAnnotationTemplates()
getAnnotationTemplates in interface IProcessorpublic void addAnnotationTemplate(AnnotationTemplate theTemplate)
addAnnotationTemplate in interface IProcessorpublic void removeAnnotationTemplate(AnnotationTemplate theTemplate)
removeAnnotationTemplate in interface IProcessorpublic AnnotationTemplate[] defaultAnnotationTemplates()
defaultAnnotationTemplates in interface IProcessorpublic AlternateProcessor[] getAlternatesArray()
getAlternatesArray in interface IProcessorpublic java.util.List getAlternatesList()
getAlternatesList in interface IProcessorpublic void addAlternate(AlternateProcessor ap)
addAlternate in interface IProcessorpublic void removeAlternate(AlternateProcessor ap)
removeAlternate in interface IProcessorpublic int getTimeout()
getTimeout in interface IProcessorpublic void setTimeout(int timeout)
setTimeout in interface IProcessorpublic int getRetries()
getRetries in interface IProcessorpublic void setRetries(int retries)
setRetries in interface IProcessorpublic int getRetryDelay()
getRetryDelay in interface IProcessorpublic void setRetryDelay(int delay)
setRetryDelay in interface IProcessorpublic double getBackoff()
getBackoff in interface IProcessorpublic void setBackoff(double backoff)
setBackoff in interface IProcessorpublic boolean getCritical()
getCritical in interface IProcessorpublic void setCritical(boolean critical)
setCritical in interface IProcessorpublic int getLogLevel()
getLogLevel in interface IProcessorpublic int getRealLogLevel()
getRealLogLevel in interface IProcessorpublic void setLogLevel(int level)
setLogLevel in interface IProcessorpublic abstract java.util.Properties getProperties()
getProperties in interface IProcessorpublic java.lang.String getName()
getName in interface IProcessorpublic java.lang.String getDescription()
getDescription in interface IProcessorpublic void setDescription(java.lang.String the_description)
setDescription in interface IProcessorpublic Port[] getPorts()
getPorts in interface IProcessorpublic InputPort[] getBoundInputPorts()
getBoundInputPorts in interface IProcessorpublic OutputPort[] getBoundOutputPorts()
getBoundOutputPorts in interface IProcessor
public Port locatePort(java.lang.String port_name)
throws UnknownPortException
locatePort in interface IProcessorUnknownPortException
public Port locatePort(java.lang.String port_name,
boolean isInputPort)
throws UnknownPortException
locatePort in interface IProcessorUnknownPortExceptionpublic InputPort[] getInputPorts()
getInputPorts in interface IProcessorpublic OutputPort[] getOutputPorts()
getOutputPorts in interface IProcessorpublic void addPort(Port the_port)
addPort in interface IProcessorpublic void removePort(Port the_port)
removePort in interface IProcessorpublic ScuflModel getModel()
getModel in interface IProcessorpublic void fireModelEvent(ScuflModelEvent event)
fireModelEvent in interface IProcessorpublic java.lang.String toString()
toString in class java.lang.Objectpublic boolean isOffline()
IProcessor
isOffline in interface IProcessor
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||