JIDE 3.5.15

com.jidesoft.grid
Class MonthCellEditor

java.lang.Object
  extended by javax.swing.AbstractCellEditor
      extended by com.jidesoft.grid.AbstractJideCellEditor
          extended by com.jidesoft.grid.ContextSensitiveCellEditor
              extended by com.jidesoft.grid.ExComboBoxCellEditor
                  extended by com.jidesoft.grid.MonthCellEditor
All Implemented Interfaces:
ConverterContextSupport, EditorContextSupport, EditorStyleSupport, JideCellEditor, ActionListener, Serializable, EventListener, CellEditor, PopupMenuListener, TableCellEditor

public class MonthCellEditor
extends ExComboBoxCellEditor

CellEditor for Month/Year. It uses MonthExComboBox to provide an editor for Calendar which has month and year value. You can override createMonthComboBox() method to provide your own MonthExComboBox.

See Also:
Serialized Form

Field Summary
static EditorContext CONTEXT
           
 
Fields inherited from class com.jidesoft.grid.ExComboBoxCellEditor
_comboBox
 
Fields inherited from class com.jidesoft.grid.ContextSensitiveCellEditor
DEFAULT_CELL_EDITOR_BORDER
 
Fields inherited from class com.jidesoft.grid.AbstractJideCellEditor
_clickCountToStart
 
Fields inherited from class javax.swing.AbstractCellEditor
changeEvent, listenerList
 
Constructor Summary
MonthCellEditor()
          Creates a MonthCellEditor.
 
Method Summary
 ExComboBox createExComboBox()
          Creates an ExComboBox or its subclass used by this cell editor.
protected  MonthExComboBox createMonthComboBox()
          Creates the month combobox used by this cell editor.
 ValidationResult validate(Object oldValue, Object newValue)
          Returns the state after validation.
 
Methods inherited from class com.jidesoft.grid.ExComboBoxCellEditor
actionPerformed, createExComboBox, customizeExComboBox, getCellEditorValue, getComboBox, getTableCellEditorComponent, isEditorStyleSupported, popupMenuCanceled, popupMenuWillBecomeInvisible, popupMenuWillBecomeVisible, setCellEditorValue, setConverter, setType, stopCellEditing
 
Methods inherited from class com.jidesoft.grid.ContextSensitiveCellEditor
getConverter, getConverterContext, getEditorContext, getEditorStyle, getType, isUseConverterContext, setConverterContext, setEditorContext, setEditorStyle, setUseConverterContext
 
Methods inherited from class com.jidesoft.grid.AbstractJideCellEditor
addValidationListener, getClickCountToStart, getDefaultErrorBehavior, getValidationListeners, isAutoStopCellEditing, isCellEditable, isPassEnterKeyToTable, removeValidationListener, setAutoStopCellEditing, setClickCountToStart, setDefaultErrorBehavior, setPassEnterKeyToTable
 
Methods inherited from class javax.swing.AbstractCellEditor
addCellEditorListener, cancelCellEditing, fireEditingCanceled, fireEditingStopped, getCellEditorListeners, removeCellEditorListener, shouldSelectCell
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface javax.swing.CellEditor
addCellEditorListener, cancelCellEditing, isCellEditable, removeCellEditorListener, shouldSelectCell
 

Field Detail

CONTEXT

public static final EditorContext CONTEXT
Constructor Detail

MonthCellEditor

public MonthCellEditor()
Creates a MonthCellEditor.

Method Detail

createExComboBox

public ExComboBox createExComboBox()
Description copied from class: ExComboBoxCellEditor
Creates an ExComboBox or its subclass used by this cell editor.

Specified by:
createExComboBox in class ExComboBoxCellEditor
Returns:
an ExComboBox.

createMonthComboBox

protected MonthExComboBox createMonthComboBox()
Creates the month combobox used by this cell editor.

Returns:
the month combobox.

validate

public ValidationResult validate(Object oldValue,
                                 Object newValue)
Description copied from class: AbstractJideCellEditor
Returns the state after validation.

Specified by:
validate in interface JideCellEditor
Overrides:
validate in class AbstractJideCellEditor
Parameters:
oldValue - the old value
newValue - the new value
Returns:
ValidateState. If it's null, it means validation passed. Only when the validation fails, it returns ValidationState.

JIDE 3.5.15