|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
The CustomAttributeEditor interface defines the default
behaviour of an editor for (custom) attributes. The setValue
method is needed during the initialization phase, while the
getValue is used to retrieve the edited value.
Editor's can be in-place, that means, they reside within the
AttributeTable, or standalone like Dialogs, Windows or Frames.
Each editor receives a call to the show method to indicate the start of the editing process. Window/Frame based Editors should be modal.
The order of calls is like this:
CustomAttributeEditor instance,setValue with the value to edit,true, getComponent is called, and then
show.
| Method Summary | |
java.lang.Object |
getComponent(CustomAttributeEditorEnvironment environment)
All those editors which return false in the
isStandalone method *must* return a valid instance of a
Component here to let the AttributeTable layout it as an
in-place editor. |
java.lang.Object |
getValue()
Returns the currently edited value of the editor. |
boolean |
isStandalone()
Returns true for all editors that display a modal dialog for
editing of the value. |
void |
setValue(java.lang.Object value)
Sets the value on the editor. |
void |
showEditor(CustomAttributeEditorEnvironment environment)
This method will be invoked to initiate the editing process. |
boolean |
wasCanceled()
This method is checked right after the showEditor
method returns. |
| Method Detail |
public void setValue(java.lang.Object value)
value - the value to be edited.public java.lang.Object getValue()
public boolean isStandalone()
true for all editors that display a modal dialog for
editing of the value. It returns false if the editor will provide an in-place
editor which will be shown inside of the AttributeEditor.
true for editors that are using a modal dialog for editingpublic java.lang.Object getComponent(CustomAttributeEditorEnvironment environment)
false in the
isStandalone method *must* return a valid instance of a
Component here to let the AttributeTable layout it as an
in-place editor. If isStandalone returns true, this method
is ignored.
NOTE: the implementation of CustomAttributeEditor is then responsible to delegate the setValue and getValue calls to this Component.
environment - The environment with information about where the editor
will be used.
Component to be used as an editor.public void showEditor(CustomAttributeEditorEnvironment environment)
environment - The environment with information about where the editor
will be used.public boolean wasCanceled()
showEditor
method returns. If an editor returns true, no further changes are made
to the value and the whole editing process is treated as it was canceled
by the user.
true, if the editor was canceled.
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||