com.sdm.quasar.client.jsf.dialog.services
Interface BrowserWindowService

All Superinterfaces:
Service
All Known Implementing Classes:
BrowserWindowFeature

public interface BrowserWindowService
extends Service

The Service shows or hides a VisualRepresentation at the current BrowserWindow. Normly a VisualRepresentation should be shown when the dialog is activated and hidden when the dialog is deactivated.

You have two strategies for showing a VisualRepresentation - modal or not - and four for hideing it concerning browser navigation:

Default is hide and reopen. Be carefull using modal dialogs and other than the default hide strategy: The browser navigation will not always match the users expection. If you use modal dialogs, make them singletons to get less problems with multi windows!

Note: Up to now there will be only one instance of a BrowserWindow, because we can't control new browser windows sufficiently. This has shortcomming for correct information about visibility of VisualRepresentation and modal dialogs that are no singletons when more than one browser windows are opend.

Author:
Martin Haft

Method Summary
 void hideVisualRepresentation(VisualRepresentation visRep, boolean recreate)
          Hides the VisualRepresentation at all BrowserWindows with hide and reopen or hide an and do not show again strategy
 void hideVisualRepresentation(VisualRepresentation visRep, java.lang.String redirectUrl)
          Hides the VisualRepresentation at all BrowserWindows.
 void hideVisualRepresentation(VisualRepresentation visRep, java.lang.String replacingDialogId, java.lang.Object context)
          Hides the VisualRepresentation at all BrowserWindows. with hide and replace by an other dielog strategy
 void showVisualRepresentation(VisualRepresentation visRep)
          Show the VisualRepresentation at the current BrowserWindow
 void showVisualRepresentation(VisualRepresentation visRep, boolean modal)
          Show the VisualRepresentation at the current BrowserWindow
 

Method Detail

showVisualRepresentation

public void showVisualRepresentation(VisualRepresentation visRep)
Show the VisualRepresentation at the current BrowserWindow

Parameters:
visRep - the VisualRepresentation be shown.

showVisualRepresentation

public void showVisualRepresentation(VisualRepresentation visRep,
                                     boolean modal)
Show the VisualRepresentation at the current BrowserWindow

Parameters:
visRep - the VisualRepresentation be shown.
modal - true if the VisualRepresentation will be modal.

hideVisualRepresentation

public void hideVisualRepresentation(VisualRepresentation visRep,
                                     boolean recreate)
Hides the VisualRepresentation at all BrowserWindows with hide and reopen or hide an and do not show again strategy

Parameters:
visRep - the VisualRepresentation to hide.
recreate - true: hide and reopen strategy; false: hide an and do not show again strategy

hideVisualRepresentation

public void hideVisualRepresentation(VisualRepresentation visRep,
                                     java.lang.String redirectUrl)
Hides the VisualRepresentation at all BrowserWindows. with hide and replace by an other page strategy

Parameters:
visRep - the VisualRepresentation to hide.
redirectUrl - the url used to redirect to the replacing page

hideVisualRepresentation

public void hideVisualRepresentation(VisualRepresentation visRep,
                                     java.lang.String replacingDialogId,
                                     java.lang.Object context)
Hides the VisualRepresentation at all BrowserWindows. with hide and replace by an other dielog strategy

Parameters:
visRep - the VisualRepresentation to hide.
replacingDialogId - the dialog id of the dialog to be shown instead of this VisualRepresentation
context - an optionally context to be used when creation the replacing dialog, may be null