Class DateChooserPanel

All Implemented Interfaces:
ImageObserver, MenuContainer, PropertyChangeListener, Serializable, EventListener, Accessible

public class DateChooserPanel extends JPanel implements PropertyChangeListener
A demonstration panel including several JDateChoosers.
Version:
$LastChangedRevision: 96 $, $LastChangedDate: 2006-05-12 18:19:35 +0200 (Fr, 12 Mai 2006) $
Author:
Kai Toedter
See Also:
  • Constructor Details

    • DateChooserPanel

      public DateChooserPanel()
  • Method Details

    • getDateFormatString

      public String getDateFormatString()
      Gets the date format string.
      Returns:
      Returns the dateFormatString.
    • setDateFormatString

      public void setDateFormatString(String dfString)
      Sets the date format string. E.g "MMMMM d, yyyy" will result in "July 21, 2004" if this is the selected date and locale is English.
      Parameters:
      dfString - The dateFormatString to set.
    • getDate

      public Date getDate()
      Returns the date. If the JDateChooser is started with an empty date and no date is set by the user, null is returned.
      Returns:
      the current date
    • setDate

      public void setDate(Date date)
      Sets the date. Fires the property change "date" if date != null.
      Parameters:
      date - the new date.
    • propertyChange

      public void propertyChange(PropertyChangeEvent evt)
      Specified by:
      propertyChange in interface PropertyChangeListener
    • getLocale

      public Locale getLocale()
      Returns the locale of the first JDateChooser.
      Overrides:
      getLocale in class Component
    • setLocale

      public void setLocale(Locale locale)
      Sets the locale of the first 4 JDateChoosers.
      Overrides:
      setLocale in class Component
    • isEnabled

      public boolean isEnabled()
      Overrides:
      isEnabled in class Component
    • setEnabled

      public void setEnabled(boolean enabled)
      Overrides:
      setEnabled in class JComponent
    • getMinSelectableDate

      public Date getMinSelectableDate()
    • setMinSelectableDate

      public void setMinSelectableDate(Date date)
    • getMaxSelectableDate

      public Date getMaxSelectableDate()
    • setMaxSelectableDate

      public void setMaxSelectableDate(Date date)