All Libraries | This Library | Package | Class | Use | Tree | Deprecated | Index | Grand Index | Help
|  | Components |
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.sas.swing.visuals
Class CalendarDialog

    com.sas.swing.visuals.CalendarDialog

All Implemented Interfaces:
  java.awt.event.ActionListener, java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable, java.util.EventListener, javax.accessibility.Accessible, javax.swing.RootPaneContainer, javax.swing.WindowConstants

    public class CalendarDialog

implements java.awt.event.ActionListener

The CalendarDialog class provides a standard modal JDialog containing a CalendarPanel. The OK button is a component of the CalendarPanel itself, not this dialog. The dialog is disposed of when the OK button is pressed. The internal CalendarPanel is accessible so that you can retrieve the user-selected date when desired.

See Also:
  Serialized Form

Field Summary
`protected CalendarPanel` | `calendarPanel`
`protected static java.lang.String` | `RB_KEY`

Constructor Summary
`CalendarDialog(java.awt.Frame owner, java.lang.String dialogTitle)` CalendarDialog constructor
`CalendarDialog(java.awt.Frame owner, java.lang.String dialogTitle, CalendarPanel panel)` CalendarDialog constructor

Method Summary
`void` | `actionPerformed(java.awt.event.ActionEvent evt)` Action event handler for the OK button
`CalendarPanel` | `getPanel()` Retrieves the internal CalendarPanel object.
`protected void` | `init(java.lang.String dialogTitle)` Initializes the dialog, creating and laying out its components.
`static void` | `main(java.lang.String[] argv)` The main application for this class, serving as a testing mechanism and an illustration of how to instantiate and configure the dialog, and retrieve values upon successful completion by the user.
`void` | `setPanel(CalendarPanel panel)` Sets the internal CalendarPanel object to display in the dialog.

Field Detail

### RB_KEY

    protected static final java.lang.String RB_KEY

See Also:
  Constant Field Values

### calendarPanel

    protected CalendarPanel calendarPanel

Constructor Detail

### CalendarDialog

    public CalendarDialog(java.awt.Frame owner,
                          java.lang.String dialogTitle)

  CalendarDialog constructor

  Parameters:
    `owner` - The Frame representing the owner of this dialog.
    `dialogTitle` - The title to appear in this dialog.

### CalendarDialog

    public CalendarDialog(java.awt.Frame owner,
                          java.lang.String dialogTitle,
                          CalendarPanel panel)

  CalendarDialog constructor

  Parameters:
    `owner` - The Frame representing the owner of this dialog.
    `dialogTitle` - The title to appear in this dialog.
    `panel` - An existing CalendarPanel object to use.

Method Detail

### getPanel

    public CalendarPanel getPanel()

  Retrieves the internal CalendarPanel object. Use this panel to access the date value specified by the user.

  Returns:
    The internal CalendarPanel instance.

### setPanel

    public void setPanel(CalendarPanel panel)

  Sets the internal CalendarPanel object to display in the dialog.

  Parameters:
    `panel` - CalendarPanel instance to use.

### init

    protected void init(java.lang.String dialogTitle)

  Initializes the dialog, creating and laying out its components.

  Parameters:
    `dialogTitle` - The title of the dialog.

### actionPerformed

    public void actionPerformed(java.awt.event.ActionEvent evt)

  Action event handler for the OK button

  Specified by:
    `actionPerformed` in interface `java.awt.event.ActionListener`

### main

    public static void main(java.lang.String[] argv)

  The main application for this class, serving as a testing mechanism and an illustration of how to instantiate and configure the dialog, and retrieve values upon successful completion by the user.

  Parameters:
    `argv` - Program arguments

All Libraries | This Library | Package | Class | Use | Tree | Deprecated | Index | Grand Index | Help
|  | Components |
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2009 SAS Institute Inc. All Rights Reserved.