diff options
author | tkellner <tkellner@174cde9d-5d70-4d2a-aa98-46368bc2aaf7> | 2013-04-10 18:53:11 +0000 |
---|---|---|
committer | tkellner <tkellner@174cde9d-5d70-4d2a-aa98-46368bc2aaf7> | 2013-04-10 18:53:11 +0000 |
commit | b2968bef5d56723826cfe38f1fe5ab1d60aa79f3 (patch) | |
tree | 8bf68cf3b7c8a6d80d3338046110a6decd60fce2 /pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/StateMachine.java | |
parent | 2e533b04ae8b232a50a83101692e20cda53696fb (diff) | |
download | pdf-over-b2968bef5d56723826cfe38f1fe5ab1d60aa79f3.tar.gz pdf-over-b2968bef5d56723826cfe38f1fe5ab1d60aa79f3.tar.bz2 pdf-over-b2968bef5d56723826cfe38f1fe5ab1d60aa79f3.zip |
State Machine refactoring
git-svn-id: https://joinup.ec.europa.eu/svn/pdf-over/trunk@23 174cde9d-5d70-4d2a-aa98-46368bc2aaf7
Diffstat (limited to 'pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/StateMachine.java')
-rw-r--r-- | pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/StateMachine.java | 44 |
1 files changed, 31 insertions, 13 deletions
diff --git a/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/StateMachine.java b/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/StateMachine.java index 92505d19..1298bda8 100644 --- a/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/StateMachine.java +++ b/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/StateMachine.java @@ -15,7 +15,7 @@ */ package at.asit.pdfover.gui.workflow; -import org.eclipse.swt.widgets.Composite; +import at.asit.pdfover.gui.workflow.states.State; /** * @@ -28,30 +28,48 @@ public interface StateMachine { public ConfigProvider getConfigProvider(); /** - * Get the container Composite - * @return the container Composite + * Get the PDF Signer + * @return the PDF Signer */ - public Composite getComposite(); - - /** - * Create a new Composite - * @param compositeClass The class of the Composite to create - * @return the new Composite - */ - public <T> T createComposite(Class<T> compositeClass); - - //public void display(Composite composite) + public PDFSigner getPDFSigner(); + /** * Get the Status * @return the Status */ public Status getStatus(); + + /** + * Gets the GUI provider + * @return the GUI provider + */ + public GUIProvider getGUIProvider(); + + /** + * Jump to specific state + * + * Sets the state machine state this method should be used to let the user jump + * around between states. This Method also resets certain properties defined + * by later states then the target state. + * + * Example: Usually the MainWindow allows the user to jump to the states: + * DataSourceSelectionState, PositioningState and BKUSelectionState + * + * @param state the state to jump to + */ + public void jumpToState(State state); /** * Update state machine * Calls the next state. */ public void update(); + + /** + * Update state machine from other thread + * Calls the next state within the main thread + */ + public void InvokeUpdate(); /** * Exit state machine execution |