org.ocd.alert
Interface IAlertManager

All Known Implementing Classes:
AlertManager

public interface IAlertManager

Provides an Interface to an Alert Manager. The alert manager can be used to display a message to the user or ask the user a confirmation question.


Field Summary
static int CANCEL
           
static int NO
           
static int NONE
           
static int OK
           
static int OK_CANCEL
           
static int YES
           
static int YES_NO
           
static int YES_NO_CANCEL
           
 
Method Summary
 int showConfirm(java.awt.Frame owner, javax.swing.Icon icon, java.lang.String title, java.lang.String message, int type)
          Ask the User for a Confirmation
 void showError(java.awt.Frame owner, javax.swing.Icon icon, java.lang.String title, java.lang.String message, java.lang.Throwable exception)
          Show an Error to the User
 void showMessage(java.awt.Frame owner, javax.swing.Icon icon, java.lang.String title, java.lang.String message)
          Show a message to the User
 IWorkInProgressAlert showWorkInProgress(java.awt.Frame owner, java.lang.String title, java.lang.String message, boolean closeable)
          Show a WorkInProgress Alert with a Status Message
 

Field Detail

NONE

public static final int NONE

OK

public static final int OK

CANCEL

public static final int CANCEL

OK_CANCEL

public static final int OK_CANCEL

YES

public static final int YES

NO

public static final int NO

YES_NO

public static final int YES_NO

YES_NO_CANCEL

public static final int YES_NO_CANCEL
Method Detail

showMessage

public void showMessage(java.awt.Frame owner,
                        javax.swing.Icon icon,
                        java.lang.String title,
                        java.lang.String message)
Show a message to the User
Parameters:
icon - to show with the Message
title - title of the dialog
message -  

showError

public void showError(java.awt.Frame owner,
                      javax.swing.Icon icon,
                      java.lang.String title,
                      java.lang.String message,
                      java.lang.Throwable exception)
Show an Error to the User
Parameters:
icon - to show with the Message
title - title of the dialog
message -  
exception - that caused this Error or null

showConfirm

public int showConfirm(java.awt.Frame owner,
                       javax.swing.Icon icon,
                       java.lang.String title,
                       java.lang.String message,
                       int type)
Ask the User for a Confirmation
Parameters:
icon - to show with the Message
title - title of the dialog
message -  
type - is the type of confirmation from IOWWorkSpace: OK_CANCEL, YES_NO, or YES_NO_CANCEL
Returns:
the id of the selection OK, CANCEL, YES, NO

showWorkInProgress

public IWorkInProgressAlert showWorkInProgress(java.awt.Frame owner,
                                               java.lang.String title,
                                               java.lang.String message,
                                               boolean closeable)
Show a WorkInProgress Alert with a Status Message
Parameters:
pTitle - title of the Alert
pMessage - message to show on WorkInProgress Alert
pCloseable - true if the alert can be closed.
Returns:
the IOWWorkInProgressAlert that was created.