|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.refractions.udig.catalog.ui.workflow.Workflow
public class Workflow
Nested Class Summary | |
---|---|
static interface |
Workflow.Listener
|
static class |
Workflow.Runner
|
static class |
Workflow.State
|
Constructor Summary | |
---|---|
Workflow()
Creates an empty workflow. |
|
Workflow(Workflow.State[] states)
Creates a workflow from a set of workflow states. |
Method Summary | ||
---|---|---|
void |
addListener(Workflow.Listener l)
Adds a listener to the workflow. |
|
protected void |
assertFinished()
|
|
protected void |
assertNotFinished()
|
|
protected void |
assertNotStarted()
|
|
protected void |
assertStarted()
|
|
protected void |
dispatchBackward(Workflow.State current,
Workflow.State next)
|
|
protected void |
dispatchFailed(Workflow.State state)
|
|
protected void |
dispatchFinished(Workflow.State last)
|
|
protected void |
dispatchForward(Workflow.State current,
Workflow.State prev)
|
|
protected void |
dispatchPassed(Workflow.State state)
|
|
protected void |
dispatchStarted(Workflow.State start)
|
|
java.lang.Object |
getContext()
Returns an object representing a context for which the states can feed off of. |
|
Workflow.State |
getCurrentState()
|
|
|
getState(java.lang.Class<T> c)
Returns a state of a specific class. |
|
Workflow.State[] |
getStates()
|
|
boolean |
hasMoreStates()
Determines if the workflow has more states. |
|
boolean |
isFinished()
|
|
protected boolean |
isPrimaryState(Workflow.State state)
|
|
boolean |
isStarted()
|
|
void |
next()
Moves the workflow to the next state. |
|
void |
next(IProgressMonitor monitor)
Moves the workflow to the next state. |
|
void |
previous()
Moves the workflow to the previous state. |
|
void |
previous(IProgressMonitor monitor)
Moves the workflow to the previous state. |
|
void |
removeListener(Workflow.Listener l)
|
|
void |
reset()
Resets the workflow. |
|
boolean |
run(IProgressMonitor monitor)
Runs the workflow from its current state. |
|
void |
setContext(java.lang.Object context)
Sets the object representing a context for which states can feed off of. |
|
void |
setStates(Workflow.State[] states)
Sets the primary set of states of the workflow. |
|
void |
start()
Starts the workflow by moving to the first state. |
|
void |
start(IProgressMonitor monitor)
Starts the workflow by moving to the first state. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Workflow()
public Workflow(Workflow.State[] states)
states
- The states of the workflow.Method Detail |
---|
public void addListener(Workflow.Listener l)
l
- The listening object.public void removeListener(Workflow.Listener l)
public java.lang.Object getContext()
public void setContext(java.lang.Object context)
context
- The context object to set.public void setStates(Workflow.State[] states)
states
- An array of states.public Workflow.State[] getStates()
public <T> T getState(java.lang.Class<T> c)
T
- The type of the state.c
- The class of the state.
public void start()
public void start(IProgressMonitor monitor)
public void next()
public void next(IProgressMonitor monitor)
public void previous()
public void previous(IProgressMonitor monitor)
public boolean isStarted()
public boolean isFinished()
public Workflow.State getCurrentState()
public boolean hasMoreStates()
public boolean run(IProgressMonitor monitor)
monitor
- A progress monitor.
public void reset()
protected void assertStarted()
protected void assertNotStarted()
protected void assertFinished()
protected void assertNotFinished()
protected boolean isPrimaryState(Workflow.State state)
protected void dispatchStarted(Workflow.State start)
protected void dispatchForward(Workflow.State current, Workflow.State prev)
protected void dispatchBackward(Workflow.State current, Workflow.State next)
protected void dispatchPassed(Workflow.State state)
protected void dispatchFailed(Workflow.State state)
protected void dispatchFinished(Workflow.State last)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |