org.jminor.common.ui.valuemap
Class DateValueLink<K>

java.lang.Object
  extended by javax.swing.AbstractAction
      extended by org.jminor.common.ui.control.Control
          extended by org.jminor.common.ui.control.AbstractValueLink<ValueChangeMapEditModel<K,V>,V>
              extended by org.jminor.common.ui.valuemap.AbstractValueMapLink<K,Object>
                  extended by org.jminor.common.ui.valuemap.TextValueLink<K>
                      extended by org.jminor.common.ui.valuemap.FormattedValueLink<K>
                          extended by org.jminor.common.ui.valuemap.DateValueLink<K>
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action

public final class DateValueLink<K>
extends FormattedValueLink<K>

A class for linking a formatted text field to a ValueChangeMapEditModel date property value.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
 
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
 
Constructor Summary
DateValueLink(JFormattedTextField textField, ValueChangeMapEditModel<K,Object> editModel, K key, LinkType linkType, DateFormat dateFormat, boolean isTimestamp)
          Instantiates a new DateValueLink.
 
Method Summary
protected  Object translate(Object parsedValue)
          
 
Methods inherited from class org.jminor.common.ui.valuemap.FormattedValueLink
getFormat, getValueAsText, getValueFromText, translate
 
Methods inherited from class org.jminor.common.ui.valuemap.TextValueLink
getText, getUIValue, isImmediateUpdate, setUIValue
 
Methods inherited from class org.jminor.common.ui.valuemap.AbstractValueMapLink
getEditModel, getKey, getModelValue, getValidationMessage, isModelValueNull, isNullable, setModelValue
 
Methods inherited from class org.jminor.common.ui.control.AbstractValueLink
actionPerformed, getLinkType, getValueOwner, updateModel, updateUI
 
Methods inherited from class org.jminor.common.ui.control.Control
getDescription, getEnabledState, getIcon, getMnemonic, getName, isEnabled, setDescription, setEnabled, setIcon, setKeyStroke, setMnemonic, setName
 
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, putValue, removePropertyChangeListener
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DateValueLink

public DateValueLink(JFormattedTextField textField,
                     ValueChangeMapEditModel<K,Object> editModel,
                     K key,
                     LinkType linkType,
                     DateFormat dateFormat,
                     boolean isTimestamp)
Instantiates a new DateValueLink.

Parameters:
textField - the text field to link
editModel - the ValueChangeMapEditModel instance
key - the key to link
linkType - the link type
dateFormat - the date format to use
isTimestamp - true if the date being linked is a timestamp
Method Detail

translate

protected Object translate(Object parsedValue)

Overrides:
translate in class FormattedValueLink<K>