|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.metamatrix.console.ui.util.property.GuiComponentFactory
public class GuiComponentFactory
The GuiComponentFactory creates JComponents and sets
their properties. All JavaBean properties can be set using this class.
For example, to create a JButton, the properties file entries
could look like this:
btn=javax.swing.JButton.class
btn.background=Color.red
btn.text="Red Button"
btn.mnemonic='R'
btn.toolTipText="This is a red button"
After the component identifier, in the above example "btn", and after
the period separator, the property name is identified starting with
a lowercase letter. A PropertyProvider identifies which properties
files are searched.
| Field Summary | |
|---|---|
static java.lang.String |
SEPARATOR
The separator used between component ID and property when composing a properties file key. |
static java.lang.String |
TYPE_DEFS_PROP
The default properties file used in the createTextField(String)
method. |
static java.lang.String |
TYPE_PREFIX
The prefix used to denote data types in property files. |
| Method Summary | |
|---|---|
static TextFieldWidget |
createTextField(java.lang.String theType)
Creates a TextFieldWidget and initializes it by using the
given type. |
static TextFieldWidget |
createTextField(java.lang.String theType,
PropertyProvider thePropProvider)
Creates a TextFieldWidget and initializes by using the given
type. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String SEPARATOR
public static final java.lang.String TYPE_DEFS_PROP
createTextField(String)
method.
public static final java.lang.String TYPE_PREFIX
| Method Detail |
|---|
public static TextFieldWidget createTextField(java.lang.String theType)
TextFieldWidget and initializes it by using the
given type. If the type is not found by the provider, a default textfield
is returned. The default provider is used.
theType - the data type key
java.lang.IllegalArgumentException - if input parameter is nullcreateTextField(String, PropertyProvider)
public static TextFieldWidget createTextField(java.lang.String theType,
PropertyProvider thePropProvider)
TextFieldWidget and initializes by using the given
type. If the type is not found by the provider, a default textfield
is returned. A typical type entry in a properties file would like like
this:
type.heapsize.length.min="1"
type.heapsize.length.max="4"
type.heapsize.cols=get("type.heapsize.length.max")
type.heapsize.required="true"
type.heapsize.validchars="0-9"
#type.heapsize.invalidchars=""
theType - the data type keythePropProvider - the provider that determines the file(s) to look
at for properties
java.lang.IllegalArgumentException - if either input parameter is
null
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||