Overview | Package | Class | Use | Tree | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.togethersoft.openapi.ide.inspector.util.editors
Class ExtendedEditor

    java.lang.Object
      |
      +--java.beans.PropertyEditorSupport
            |
            +--com.togethersoft.openapi.ide.inspector.util.editors.SwingEditorSupport
                  |
                  +--com.togethersoft.openapi.ide.inspector.util.editors.ExtendedEditor

Direct Known Subclasses:
  ExtendedFileNameEditor, ExtendedStringEditor, MultiValueEditor, SingleElementChooserEditor

public abstract class ExtendedEditor
extends SwingEditorSupport
implements CellEditorListener

Represents two ways to edit cell value - by inner editor and extended editor. This class takes existing inner editor and when user clicks to the cell it calls inner editor. When user clicks to the small iconified button on the right side of the cell the method doAction() is called. By this way it is possible to add custom editor for certain type of property. This class uses ExtendedControl to vizualize extended editor. Extenders of this class must implement the `doAction` method.

Author:
  TogetherSoft
See Also: ExtendedControl

Fields inherited from class com.togethersoft.openapi.ide.inspector.util.editors.SwingEditorSupport
`MEDIUM_DIMENSION, panel, SMALL_DIMENSION`

Constructor Summary
`ExtendedEditor(PropertyEditor innerEditor)` Constructs this editor.

Method Summary
`protected void` | `doAction()` This method has to be overridden in order to construct extended editor control.
`void` | `editingCanceled(ChangeEvent e)` Called when user cancelled editing.
`void` | `editingStopped(ChangeEvent e)` Called when user cancelled editing.
`int` | `getChooserType()` Returns type of button which is used to call extended editor.
`protected PropertyEditor` | `getInnerEditor()` Returns inner editor which is used by this ExtendedEditor.
`Object` | `getValue()` Fetches value from the inner editor.
`void` | `setValue(Object obj)` Passes value to the inner editor.

Methods inherited from class com.togethersoft.openapi.ide.inspector.util.editors.SwingEditorSupport
`addCellEditorListener, fireEditingCanceled, fireEditingStopped, getCustomEditor, init, removeCellEditorListener, setAlignment, supportsCustomEditor`

Methods inherited from class java.beans.PropertyEditorSupport
`isPaintable, paintValue, getJavaInitializationString, getAsText, setAsText, getTags, addPropertyChangeListener, removePropertyChangeListener, firePropertyChange`

Methods inherited from class java.lang.Object
`getClass, hashCode, equals, clone, toString, notify, notifyAll, wait, wait, wait, finalize`

Constructor Detail

### ExtendedEditor

    public ExtendedEditor(PropertyEditor innerEditor)

  Constructs this editor. If specified inner editor supports custom editor then creates ExtendedControl on the base of the custom editor supported by this inner editor.

Method Detail

### doAction

    protected void doAction()

  This method has to be overridden in order to construct extended editor control.

### editingCanceled

    public void editingCanceled(ChangeEvent e)

  Called when user cancelled editing.

### editingStopped

    public void editingStopped(ChangeEvent e)

  Called when user cancelled editing.

### getChooserType

    public int getChooserType()

  Returns type of button which is used to call extended editor.
  Returns: ExtendedControl.CHOOSER_BUTTON
  See Also:
    com.togethersoft.openapi.util.ui.ExtendedControl.CHOOSER_BUTTON, com.togethersoft.openapi.util.ui.ExtendedControl.FILE_CHOOSER_BUTTON

### getInnerEditor

    protected PropertyEditor getInnerEditor()

  Returns inner editor which is used by this ExtendedEditor.

### getValue

    public Object getValue()

  Fetches value from the inner editor.

### setValue

    public void setValue(Object obj)

  Passes value to the inner editor.

Association Links

to Class com.togethersoft.openapi.util.ui.ExtendedControl

to Class java.awt.event.ActionListener

to Class java.beans.PropertyEditor

Overview | Package | Class | Use | Tree | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD