|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.eclipse.emf.mwe.core.lib.AbstractWorkflowComponent
public abstract class AbstractWorkflowComponent
Base class useful for implementing custom WorkflowComponents.
Constructor Summary | |
---|---|
AbstractWorkflowComponent()
|
Method Summary | |
---|---|
void |
checkRequiredConfigProperty(java.lang.String configPropertyName,
java.lang.Object configPropertyValue,
Issues issues)
Utility method that can be used in method checkConfiguration
to check required properties. |
protected Mwe2Bridge |
getBridge()
|
java.lang.String |
getComponentName()
Returns the component's name. |
CompositeComponent |
getContainer()
Returns the containing component if there is one. |
java.lang.String |
getId()
Returns the ID of the component. |
Location |
getLocation()
Returns the location in the source file that invokes the current component. |
java.lang.String |
getLogMessage()
Returns the log message, |
void |
invoke(IWorkflowContext ctx)
|
void |
invoke(WorkflowContext ctx,
ProgressMonitor monitor,
Issues issues)
Invokes the component. |
protected abstract void |
invokeInternal(WorkflowContext ctx,
ProgressMonitor monitor,
Issues issues)
Internal method for component execution. |
void |
postInvoke()
|
void |
preInvoke()
|
void |
setContainer(CompositeComponent container)
Sets the containing component. |
void |
setId(java.lang.String id)
Sets the ID of the workflow component. |
void |
setLocation(Location location)
Sets the location in the source file that invokes the current component. |
void |
setSkipOnErrors(boolean skipOnErrors)
Sets if the current component should be skipped if previous components caused errors. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.eclipse.emf.mwe.core.WorkflowComponent |
---|
checkConfiguration |
Constructor Detail |
---|
public AbstractWorkflowComponent()
Method Detail |
---|
public void checkRequiredConfigProperty(java.lang.String configPropertyName, java.lang.Object configPropertyValue, Issues issues)
checkConfiguration
to check required properties. If configPropertyValue
is
null
or a blank string then this method will add an error
issue.
configPropertyName
- Name of the checked config property.configPropertyValue
- The config property value.issues
- The Issues instance.public java.lang.String getComponentName()
getComponentName
in interface WorkflowComponent
public CompositeComponent getContainer()
WorkflowComponent
getContainer
in interface WorkflowComponent
public java.lang.String getId()
WorkflowComponentWithID
getId
in interface WorkflowComponentWithID
WorkflowComponentWithID.getId()
public Location getLocation()
WorkflowComponent
getLocation
in interface WorkflowComponent
WorkflowComponent.getLocation()
public java.lang.String getLogMessage()
WorkflowComponentWithID
getLogMessage
in interface WorkflowComponentWithID
WorkflowComponentWithID.getLogMessage()
public final void invoke(WorkflowContext ctx, ProgressMonitor monitor, Issues issues)
WorkflowComponent
invoke
in interface WorkflowComponent
ctx
- current workflow contextmonitor
- implementors should provide some feedback about the progress
using this monitorWorkflowComponent.invoke(org.eclipse.emf.mwe.core.WorkflowContext,
org.eclipse.emf.mwe.core.monitor.ProgressMonitor,
org.eclipse.emf.mwe.core.issues.Issues)
public void setContainer(CompositeComponent container)
WorkflowComponent
setContainer
in interface WorkflowComponent
container
- the containing componentWorkflowComponent.setContainer(org.eclipse.emf.mwe.core.container.CompositeComponent)
public void setId(java.lang.String id)
WorkflowComponentWithID
setId
in interface WorkflowComponentWithID
id
- the IDWorkflowComponentWithID.setId(java.lang.String)
public void setLocation(Location location)
WorkflowComponent
setLocation
in interface WorkflowComponent
location
- the locationWorkflowComponent.setLocation(org.eclipse.emf.mwe.internal.core.ast.parser.Location)
public void setSkipOnErrors(boolean skipOnErrors)
skipOnErrors
- if true
, the current component is skipped if
errors have occurred, if false
, the component is
not skipped.protected abstract void invokeInternal(WorkflowContext ctx, ProgressMonitor monitor, Issues issues)
ctx
- the workflow contextmonitor
- the progress monitorissues
- container of execution issuesprotected Mwe2Bridge getBridge()
public void preInvoke()
preInvoke
in interface IWorkflowComponent
public void invoke(IWorkflowContext ctx)
invoke
in interface IWorkflowComponent
public void postInvoke()
postInvoke
in interface IWorkflowComponent
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |