Oracle Fusion Middleware Java API Reference for Oracle Extension SDK Reference
11g Release 1 (11.1.1.6.0)

E13403-07

oracle.javatools.dialogs
Class BaseMessageDialog

java.lang.Object
  extended by java.awt.Component
      extended by java.awt.Container
          extended by java.awt.Window
              extended by java.awt.Dialog
                  extended by javax.swing.JDialog
                      extended by oracle.bali.ewt.dialog.JEWTDialog
                          extended by oracle.javatools.dialogs.BaseMessageDialog
All Implemented Interfaces:
java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable, javax.accessibility.Accessible, javax.swing.RootPaneContainer, javax.swing.WindowConstants
Direct Known Subclasses:
BaseMessageDialog

public class BaseMessageDialog
extends oracle.bali.ewt.dialog.JEWTDialog

Subclass of JEWTDialog that implements the message dialog. You should normally use MessageDialog, but BaseMessageDialog can be used for custom alerts.

See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class javax.swing.JDialog
javax.swing.JDialog.AccessibleJDialog
 
Nested classes/interfaces inherited from class java.awt.Dialog
java.awt.Dialog.AccessibleAWTDialog, java.awt.Dialog.ModalExclusionType, java.awt.Dialog.ModalityType
 
Nested classes/interfaces inherited from class java.awt.Window
java.awt.Window.AccessibleAWTWindow
 
Nested classes/interfaces inherited from class java.awt.Container
java.awt.Container.AccessibleAWTContainer
 
Nested classes/interfaces inherited from class java.awt.Component
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BaselineResizeBehavior, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy
 
Field Summary
static int TYPE_ALERT
          The look and feel dependent alert/confirmation icon.
static int TYPE_APPLICATION_ERROR
          The look and feel dependent error icon.
static int TYPE_CONFIRM_OR_CANCEL
          confirm or cancel
static int TYPE_CONFIRMATION
          The look and feel dependent confirmation icon.
static int TYPE_INFORMATION
          The look and feel dependent information icon.
 
Fields inherited from class oracle.bali.ewt.dialog.JEWTDialog
ACTION_APPLY, BUTTON_APPLY, BUTTON_CANCEL, BUTTON_CLOSE, BUTTON_DEFAULT, BUTTON_HELP, BUTTON_NONE, BUTTON_OK, PROPERTY_CLOSED
 
Fields inherited from class javax.swing.JDialog
accessibleContext, rootPane, rootPaneCheckingEnabled
 
Fields inherited from class java.awt.Dialog
DEFAULT_MODALITY_TYPE
 
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
 
Fields inherited from interface javax.swing.WindowConstants
DISPOSE_ON_CLOSE, DO_NOTHING_ON_CLOSE, EXIT_ON_CLOSE, HIDE_ON_CLOSE
 
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
 
Constructor Summary
protected BaseMessageDialog(java.awt.Dialog owner, java.lang.String title, int buttonMask)
           
protected BaseMessageDialog(java.awt.Frame owner, java.lang.String title, int buttonMask)
           
 
Method Summary
static BaseMessageDialog createMessageDialogImpl(java.awt.Component parent, java.lang.String title, int messageType)
          Convenience static method which creates a JEWTMessageDialog.
protected  boolean runActualDialog()
           
 boolean runDialog()
          Run the dialog
 void setHelpTopic(java.lang.String id)
          Set the help topic ID
 void setMessage(java.lang.Object msg)
           
 void setMessageText(java.lang.String message)
          Set the message that is displayed
 void setMessageText(java.lang.String message, java.lang.Object[] substitute)
          Convenience method that is identical to setMessageText(MessageFormat.format( message, substitute ) );
 void setMessageType(int type)
          Set the message type.
 
Methods inherited from class oracle.bali.ewt.dialog.JEWTDialog
addActionListener, addCustomButton, addNotify, addPropertyChangeListener, addVetoableChangeListener, closeDialog, createDialog, dialogInit, dismissDialog, dispose, firePropertyChange, fireVetoableChange, getAccessibleContext, getButtonMask, getButtonMnemonic, getCancelButtonMnemonic, getCancelButtonText, getCenterOver, getContent, getCustomButton, getCustomButtonCount, getDefaultButton, getDialogHeader, getInitialFocus, getMaximumInitialSize, getMaximunInitialSize, getMinimumSize, getOKButtonMnemonic, getOKButtonText, getPreferredSize, getValidationMessagePane, isCancelled, isDialogClosingEvent, isOKButtonEnabled, pack, processActionEvent, processComponentEvent, processEvent, processWindowEvent, removeActionListener, removeCustomButton, removePropertyChangeListener, removeVetoableChangeListener, runDialog, setButtonMask, setCancelButtonMnemonic, setCancelButtonText, setCenterOver, setContent, setDefaultButton, setDialogHeader, setInitialFocus, setInitialFocus, setMaximumInitialSize, setMaximumInitialSize, setMinimumSize, setMinimumSize, setOKButtonEnabled, setOKButtonMnemonic, setOKButtonText, setPreferredSize, setPreferredSize, setValidationMessagePane
 
Methods inherited from class javax.swing.JDialog
addImpl, createRootPane, getContentPane, getDefaultCloseOperation, getGlassPane, getGraphics, getJMenuBar, getLayeredPane, getRootPane, getTransferHandler, isDefaultLookAndFeelDecorated, isRootPaneCheckingEnabled, paramString, remove, repaint, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, setTransferHandler, update
 
Methods inherited from class java.awt.Dialog
getModalityType, getTitle, hide, isModal, isResizable, isUndecorated, setModal, setModalityType, setResizable, setTitle, setUndecorated, setVisible, show, toBack
 
Methods inherited from class java.awt.Window
addPropertyChangeListener, addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getFocusTraversalKeys, getGraphicsConfiguration, getIconImages, getInputContext, getListeners, getLocale, getModalExclusionType, getMostRecentFocusOwner, getOwnedWindows, getOwner, getOwnerlessWindows, getToolkit, getWarningString, getWindowFocusListeners, getWindowListeners, getWindows, getWindowStateListeners, isActive, isAlwaysOnTop, isAlwaysOnTopSupported, isFocusableWindow, isFocusCycleRoot, isFocused, isLocationByPlatform, isShowing, paint, postEvent, processWindowFocusEvent, processWindowStateEvent, removeNotify, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, reshape, setAlwaysOnTop, setBounds, setBounds, setCursor, setFocusableWindowState, setFocusCycleRoot, setIconImage, setIconImages, setLocationByPlatform, setLocationRelativeTo, setModalExclusionType, setSize, setSize, toFront
 
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalPolicy, getInsets, getLayout, getMaximumSize, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, transferFocusBackward, transferFocusDownCycle, validate, validateTree
 
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBaseline, getBaselineResizeBehavior, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isPreferredSizeSet, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resize, resize, setBackground, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setMaximumSize, setName, show, size, toString, transferFocus, transferFocusUpCycle
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

TYPE_APPLICATION_ERROR

public static final int TYPE_APPLICATION_ERROR
The look and feel dependent error icon. This should be used only for non-user errors. Only the OK and Help buttons are displayed

See Also:
Constant Field Values

TYPE_INFORMATION

public static final int TYPE_INFORMATION
The look and feel dependent information icon. Using this dialog type will also stop the Cancel and Help buttons from being displayed ( see the Oracle Dialog Spec).

See Also:
Constant Field Values

TYPE_ALERT

public static final int TYPE_ALERT
The look and feel dependent alert/confirmation icon. Using this dialog type will also stop the Cancel button being displayed ( see the Oracle Dialog spec)

See Also:
Constant Field Values

TYPE_CONFIRMATION

public static final int TYPE_CONFIRMATION
The look and feel dependent confirmation icon. According to the Oracle Dialog spec, the icon should be the same as TYPE_ALERT. Using this dialog type will also change the default buttons from Cancel | OK to No | Yes.

See Also:
Constant Field Values

TYPE_CONFIRM_OR_CANCEL

public static final int TYPE_CONFIRM_OR_CANCEL
confirm or cancel

See Also:
Constant Field Values
Constructor Detail

BaseMessageDialog

protected BaseMessageDialog(java.awt.Frame owner,
                            java.lang.String title,
                            int buttonMask)

BaseMessageDialog

protected BaseMessageDialog(java.awt.Dialog owner,
                            java.lang.String title,
                            int buttonMask)
Method Detail

createMessageDialogImpl

public static BaseMessageDialog createMessageDialogImpl(java.awt.Component parent,
                                                        java.lang.String title,
                                                        int messageType)
Convenience static method which creates a JEWTMessageDialog. This method does not display the dialog. You need to call the runDialog() method to actually make the message dialog appear.

Parameters:
parent - The parent of the dialog. The first ancestor Dialog in the component tree will be used as the parent of the dialog. Failing that, the first ancestor Frame will be used. If the component has no ancestor frame, this method will throw an IllegalArgumentException. Passing null into this method will also result in an IllegalArgumentException being thrown.
title - The title of the dialog. Often, this is the application name.
messageType - The type of icon that will be displayed in the dialog. This should be one of the TYPE_ static finals in this class.
Returns:
The JEWTMessageDialog which was constructed.
Throws:
java.lang.IllegalArgumentException - if the specified component does not have a Frame or Dialog ancestor, or the specified component is null.

setMessage

public void setMessage(java.lang.Object msg)

setMessageText

public void setMessageText(java.lang.String message)
Set the message that is displayed

Parameters:
message - The message to display.

setMessageText

public void setMessageText(java.lang.String message,
                           java.lang.Object[] substitute)
Convenience method that is identical to setMessageText(MessageFormat.format( message, substitute ) );

Parameters:
message - The message to display
substitute - Parameters to substitute into message

setMessageType

public void setMessageType(int type)
Set the message type.

Parameters:
messageType - - TYPE_ALERT, TYPE_CONFIRMATION, TYPE_ERROR or TYPE_INFORMATION

setHelpTopic

public void setHelpTopic(java.lang.String id)
Set the help topic ID

Parameters:
id - the help topic id

runActualDialog

protected boolean runActualDialog()

runDialog

public boolean runDialog()
Run the dialog

Overrides:
runDialog in class oracle.bali.ewt.dialog.JEWTDialog

Oracle Fusion Middleware Java API Reference for Oracle Extension SDK Reference
11g Release 1 (11.1.1.6.0)

E13403-07

Copyright © 1997, 2011, Oracle. All rights reserved.