|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Editor
This interface describes general editors that have an Icon, title, ToolBar, and that can set and return a model.
AbstractEditor
Method Summary | |
---|---|
void |
activate()
Activates this editor. |
void |
deactivate()
Deactivates the editor. |
Icon |
getIcon()
Returns this editor's icon. |
JComponent |
getPanel()
Returns this editor's panel. |
String |
getTitle()
Returns this editor's title. |
JToolBar |
getToolBar()
Returns this editor's tool bar. |
void |
updateModel(Object model)
Reads the values from this editor's components and sets them in the given model. |
void |
updateView(Object model)
Reads the values from the given model and sets them in this editor's components. |
Method Detail |
---|
Icon getIcon()
String getTitle()
JToolBar getToolBar()
JComponent getPanel()
void activate()
Implementors may choose to do nothing or update the view. This depends on who can change domain objects. If only editors can change the domain, you likely need not update the view on editor activation. If the domain objects can be changed by third parties, you may need to update the view if an editor gets activated.
Implementors may also need to perform additional actions on activation. For example, scroll a list or table to make the current selection visible.
void deactivate()
Typically an implementor needs to update the model data by copying values from this editor's components to the model.
void updateModel(Object model)
model
- the object to write this editor's value tovoid updateView(Object model)
model
- the object to read the values from
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |