|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: REQUIRED | OPTIONAL | DETAIL: ELEMENT | |||||||||
@Retention(value=RUNTIME) public @interface EditorConfig
Annotation used by the GenericObjectEditor to build the Editor GUI.
Annotate a class like this:
@EditorConfig(name="My Object", editor="org.mycompany.MyEditor")
public class ObjectToEdit() {
...
}
to configure the way the object will appear in a generated form GUI.
@EditorConfig(name="My field", index=0, editor="org.mycompany.MyRenderer")
public String getSomething() {
...
}
and the return value of the method will be edited in a generated form GUI.
| Optional Element Summary | |
|---|---|
String |
description
Gives a displayable description for the edited field/type. |
String |
editable
Set the editor the editable or not (the isEditable() in swing components). |
String |
editor
Full class name of the editor ObjectEditor to use. |
String |
enabled
Set the editor the enabled or not (the isEnabled() in swing components). |
int |
index
Gives the preferred field editor position. |
String |
label
Gives a displayable name for the edited field/type. |
String |
list
Key of a list to use: this parameter can be interpreted differently (or ignored) by each editor. |
String[] |
properties
List of properties: The returned array must contain an odd number of strings, each time the property id followed by the property value. |
String |
tab
Id of the Tab where to display the field: this parameter can be interpreted differently (or ignored) by each editor. |
String |
type
Type of editor: this parameter can be interpreted differently (or ignored) by each editor. |
String |
visibility
Definition editor the visibility. |
public abstract String label
The given string can reference an attribute (with "") or a method (with "{$...}") of the edited object. In this
case, the specified method is called on the edited object to get the label.
See net.sf.sfac.gui.editor.access.ModelAccessFactory class javadoc for more info.
public abstract String description
The given string can reference an attribute (with "") or a method (with "{$...}") of the edited object. In this
case, the specified method is called on the edited object to get the description.
See net.sf.sfac.gui.editor.access.ModelAccessFactory class javadoc for more info.
public abstract int index
public abstract String editor
public abstract String editable
The given string can reference an attribute (with "") or a method (with "{$...}") of the edited object. In this
case, the specified method is called on the edited object to get the editable attribute.
See net.sf.sfac.gui.editor.access.ModelAccessFactory class javadoc for more info.
public abstract String enabled
The given string can reference an attribute (with "") or a method (with "{$...}") of the edited object. In this
case, the specified method is called on the edited object to get the enabled attribute.
See net.sf.sfac.gui.editor.access.ModelAccessFactory class javadoc for more info.
public abstract String visibility
The given string can reference an attribute (with "") or a method (with "{$...}") of the edited object. In this
case, the specified method is called on the edited object to get the visibility.
See net.sf.sfac.gui.editor.access.ModelAccessFactory class javadoc for more info.
public abstract String type
For example, with the StringEditor, you can use type="line" (the default) or type="text" to have a single-line (i.e. * JTextField) or a multi-line (i.e. JTextArea) string editor.
public abstract String list
getContextObject(key))
public abstract String tab
public abstract String[] properties
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: REQUIRED | OPTIONAL | DETAIL: ELEMENT | |||||||||