org.opensubsystems.core.application
Interface ThickClientModule

All Known Subinterfaces:
SWTThickClientModule
All Known Implementing Classes:
ExitModule, SeparatorModule, SWTExitModule, ThickClientModuleImpl

public interface ThickClientModule

Interface representing thick client module, which is either specific action executed when activated or set of screens acting together. The lifecycle of the thick client module is 1. constructor 2. init if ever acticated 3. activate if ever acticated 4. optional refresh if invoked by functionality 5. optional pasivate 6. optional activate if previously pasivated + refresh 7. repeat 4 - 6 8. destroy

Version:
$Id: ThickClientModule.java,v 1.7 2007/01/07 06:14:39 bastafidli Exp $
Author:
Miro Halas
Code reviewer:
Miro Halas
Code reviewed:
1.5 2006/03/13 15:41:48 bastafidli

Method Summary
 boolean activate(boolean bReactivate)
          Activate the module so that user can interact with it.
 void destroy()
          Destroy the module since the application is shutting down.
 java.lang.Object displayMessage(java.lang.String strTitle, java.lang.String strMessage, java.lang.Object additionalInfo)
          Display message to the user.
 ThickClient getClient()
          Get client displaing this module.
 java.lang.String getName()
          Get user friedly name UNIQUE name of the module.
 void init(ThickClient client)
          Initialize the module for a specified client.
 void pasivate()
          Pasivate the module since user no longer interacts with it.
 void refresh()
          Refresh the currently displayed screen of this module with the latest data.
 

Method Detail

getName

java.lang.String getName()
Get user friedly name UNIQUE name of the module.

Returns:
String

getClient

ThickClient getClient()
Get client displaing this module.

Returns:
ThickClient

init

void init(ThickClient client)
          throws OSSException
Initialize the module for a specified client. This method may not need to be called immediately after the module is constructed. It may be delayed until the module is actually accesed to speed up start up of application. It must be called before any other lifecycle method in this interface is invoked.

Parameters:
client - - client using this module
Throws:
OSSException - - an error has occured

activate

boolean activate(boolean bReactivate)
Activate the module so that user can interact with it.

Parameters:
bReactivate - - this is true if the module was pasivated but it is being immediately activated again because the other module which caused it's pasivation coun't be activated again. This is false if some other module was active and now this module is being activated.
Returns:
boolean - true if sucessfully activated false if cannot be activated and either the previously active module should remain active or no module should be active

pasivate

void pasivate()
Pasivate the module since user no longer interacts with it.


refresh

void refresh()
Refresh the currently displayed screen of this module with the latest data. This method will be called for example when user switches between two modules.


destroy

void destroy()
Destroy the module since the application is shutting down.


displayMessage

java.lang.Object displayMessage(java.lang.String strTitle,
                                java.lang.String strMessage,
                                java.lang.Object additionalInfo)
Display message to the user.

Parameters:
strTitle - - title of the message, look at MESSAGE_TITLE_XXX constants in ThickClienGui interface
strMessage - - message to display
additionalInfo - - additional information to pass in, this may be implementation specific, look at MESSAGE_STYLE_XXX constants in ThickClienGui interface
Returns:
Object - result of the message, this may be implementation specific


Copyright © 2003 - 2006 OpenSubsystems s.r.o.