|
JClass DesktopViews 6.3.0 API Documentation |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object
|
+--java.awt.Component
|
+--java.awt.Container
|
+--javax.swing.JComponent
|
+--javax.swing.text.JTextComponent
|
+--javax.swing.JTextField
|
+--com.klg.jclass.field.JCTextField
JCTextField has all the capability of JTextField,
as well as the ability to validate its contents.
JTextField,
Serialized Form| Nested Class Summary |
| Nested classes inherited from class javax.swing.JTextField |
JTextField.AccessibleJTextField |
| Nested classes inherited from class javax.swing.text.JTextComponent |
JTextComponent.AccessibleJTextComponent, JTextComponent.KeyBinding |
| Nested classes inherited from class javax.swing.JComponent |
JComponent.AccessibleJComponent |
| Nested classes inherited from class java.awt.Container |
Container.AccessibleAWTContainer |
| Nested classes inherited from class java.awt.Component |
Component.AccessibleAWTComponent, Component.BltBufferStrategy, Component.FlipBufferStrategy |
| Field Summary | |
protected com.klg.jclass.field.Field |
field
|
protected boolean |
required
|
static String |
version
Contains the version number of the JClass product. |
| Fields inherited from class javax.swing.JTextField |
notifyAction |
| Fields inherited from class javax.swing.text.JTextComponent |
DEFAULT_KEYMAP, FOCUS_ACCELERATOR_KEY |
| Fields inherited from class javax.swing.JComponent |
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
| Fields inherited from class java.awt.Component |
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
| Fields inherited from interface com.klg.jclass.field.JCFieldComponent |
INVALID, UNDEREDIT, VALID |
| Fields inherited from interface javax.swing.SwingConstants |
BOTTOM, CENTER, EAST, HORIZONTAL, LEADING, LEFT, NEXT, NORTH, NORTH_EAST, NORTH_WEST, PREVIOUS, RIGHT, SOUTH, SOUTH_EAST, SOUTH_WEST, TOP, TRAILING, VERTICAL, WEST |
| Fields inherited from interface java.awt.image.ImageObserver |
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
| Constructor Summary | |
JCTextField()
Constructs an empty JCTextField. |
|
JCTextField(Class c)
Constructs an empty JCTextField, which expects an object of the
specified class. |
|
JCTextField(Class c,
com.klg.jclass.field.validate.JCValidator v)
Constructs an empty JCTextField, which expects an object of the
specified class and uses the specified validator. |
|
JCTextField(int columns)
Constructs a JCTextField with the specified number of columns. |
|
JCTextField(com.klg.jclass.util.value.JCValueModel m)
Constructs an empty JCTextField, which uses the specified value
model to contain its value. |
|
JCTextField(com.klg.jclass.util.value.JCValueModel m,
com.klg.jclass.field.validate.JCValidator v)
Constructs an empty JCTextField, which uses the specified value
model to contain its value and uses the specified validator. |
|
JCTextField(String text)
Constructs a JCTextField initialized with the specified text. |
|
JCTextField(String text,
int columns)
Constructs an empty JCTextField with the specified number of
columns and initialized with the specified text. |
|
| Method Summary | |
void |
addNotify()
Initializes the field object. |
void |
addPropertyChangeListener(PropertyChangeListener listener)
Adds a PropertyChangeListener to the listener list. |
void |
addValueListener(com.klg.jclass.util.value.JCValueListener listener)
Adds a listener to listen for changes to the value. |
void |
commitEdit()
Commits the current field under edit. |
protected void |
createField(com.klg.jclass.field.validate.JCValidator validator)
Creates the field object which controls the validation. |
String |
getAbout()
Gets the value of the About property. |
com.klg.jclass.field.DataProperties |
getDataProperties()
Gets the Bean property which wraps the validator, data model, and Field objects properties into one property. |
com.klg.jclass.field.JCInvalidInfo |
getInvalidInfo()
Returns the Invalid properties. |
boolean |
getSelectOnEnter()
Returns a flag indicating the selection status on entering the field. |
int |
getState()
Returns the state of the component. |
com.klg.jclass.field.validate.JCValidator |
getValidator()
Returns the validator currently in use. |
Object |
getValue()
Returns the value for the text field. |
com.klg.jclass.util.value.JCValueModel |
getValueModel()
Returns the data model being used by the field. |
boolean |
isRequired()
Returns true if the field is required. |
void |
removePropertyChangeListener(PropertyChangeListener listener)
Removes a PropertyChangeListener from the listener list. |
void |
removeValueListener(com.klg.jclass.util.value.JCValueListener listener)
Removes a listener which listens for changes to the value. |
void |
setAbout(String s)
Sets the value of the About property. |
void |
setBackground(Color background)
Sets the background color of the text field. |
void |
setDataProperties(com.klg.jclass.field.DataProperties dp)
Sets the Bean property which wraps the validator, data model, and Field objects properties into one property. |
void |
setEditable(boolean b)
Overrides setEditable to make sure the background is set to the
correct color immediately (otherwise the setBackground() method
above will intercept the change and nothing will happen until the user tries
to edit the field). |
void |
setForeground(Color foreground)
Sets the foreground color of the text field. |
void |
setInvalidInfo(com.klg.jclass.field.JCInvalidInfo info)
Sets the Invalid properties. |
void |
setLocale(Locale l)
Sets the locale being used by the text field; sets it on the validator as well. |
void |
setRequired(boolean required)
Sets the required property for the current field. |
void |
setSelectOnEnter(boolean select)
Sets a flag that determines whether or not the value in the field is selected when the component gains focus. |
void |
setValidator(com.klg.jclass.field.validate.JCValidator validator)
Sets the validator to use. |
void |
setValue(Object value)
Sets the value for the text field. |
void |
setValueModel(com.klg.jclass.util.value.JCValueModel model)
Sets the data model being used by the field. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
protected com.klg.jclass.field.Field field
protected boolean required
public static final String version
| Constructor Detail |
public JCTextField()
JCTextField.
public JCTextField(Class c)
JCTextField, which expects an object of the
specified class.
c - the class type the field will expect
public JCTextField(Class c,
com.klg.jclass.field.validate.JCValidator v)
JCTextField, which expects an object of the
specified class and uses the specified validator.
c - the class type the field will expectv - the validator that validates input in the fieldpublic JCTextField(com.klg.jclass.util.value.JCValueModel m)
JCTextField, which uses the specified value
model to contain its value.
m - the value model that contains the value
public JCTextField(com.klg.jclass.util.value.JCValueModel m,
com.klg.jclass.field.validate.JCValidator v)
JCTextField, which uses the specified value
model to contain its value and uses the specified validator.
m - the value model that contains the valuev - the validator that validates input in the fieldpublic JCTextField(String text)
JCTextField initialized with the specified text.
text - the text with which to initialize the fieldpublic JCTextField(int columns)
JCTextField with the specified number of columns.
columns - the number of columns
public JCTextField(String text,
int columns)
JCTextField with the specified number of
columns and initialized with the specified text.
text - the text with which to initialize the fieldcolumns - the number of columns| Method Detail |
public com.klg.jclass.field.DataProperties getDataProperties()
Field objects properties into one property.
getDataProperties in interface JCFieldComponentDataProperties Bean wrapperJCValidator,
JCValueModel,
JCInvalidInfopublic void setDataProperties(com.klg.jclass.field.DataProperties dp)
Field objects properties into one property.
setDataProperties in interface JCFieldComponentdp - the new DataProperties valueJCValidator,
JCValueModel,
JCInvalidInfopublic void addPropertyChangeListener(PropertyChangeListener listener)
PropertyChangeListener to the listener list.
addPropertyChangeListener in class JComponentlistener - the PropertyChangeListener to be addedpublic void removePropertyChangeListener(PropertyChangeListener listener)
PropertyChangeListener from the listener list.
This removes a PropertyChangeListener that was registered
for all properties.
removePropertyChangeListener in class JComponentlistener - the PropertyChangeListener to be removedpublic void addValueListener(com.klg.jclass.util.value.JCValueListener listener)
addValueListener in interface JCFieldComponentlistener - the JCValueListener to be addedpublic void removeValueListener(com.klg.jclass.util.value.JCValueListener listener)
removeValueListener in interface JCFieldComponentlistener - the JCValueListener to be removedpublic void addNotify()
addNotify in class JComponentprotected void createField(com.klg.jclass.field.validate.JCValidator validator)
validator - the object which does the validationpublic String getAbout()
About property. The About
property displays contact information for Quest Software in the
Bean box.
public void setAbout(String s)
About property. The About
property displays contact information for Quest Software in the
bean box.
s - the new about String (ignored)public void setBackground(Color background)
setBackground in class JComponentbackground - the new background colorpublic void setForeground(Color foreground)
setForeground in class JComponentforeground - the new foreground colorpublic Object getValue()
getValue in interface JCFieldComponentpublic void setValue(Object value)
setValue in interface JCFieldComponentvalue - the new value of the fieldpublic com.klg.jclass.util.value.JCValueModel getValueModel()
getValueModel in interface JCFieldComponentJCValueModelpublic void setValueModel(com.klg.jclass.util.value.JCValueModel model)
setValueModel in interface JCFieldComponentmodel - the new value model for the fieldJCValueModelpublic com.klg.jclass.field.validate.JCValidator getValidator()
getValidator in interface JCFieldComponentJCValidatorpublic void setValidator(com.klg.jclass.field.validate.JCValidator validator)
setValidator in interface JCFieldComponentvalidator - the new validator for the fieldJCValidatorpublic com.klg.jclass.field.JCInvalidInfo getInvalidInfo()
Invalid properties. The Invalid
properties are beepOnInvalid, invalidForeground,
invalidBackground, defaultValue, and
invalidPolicy.
getInvalidInfo in interface JCFieldComponentpublic void setInvalidInfo(com.klg.jclass.field.JCInvalidInfo info)
Invalid properties. The Invalid properties
are beepOnInvalid, invalidForeground,
invalidBackground, defaultValue, and
invalidPolicy.
setInvalidInfo in interface JCFieldComponentinfo - the new Invalid information objectpublic int getState()
getState in interface JCFieldComponentJCFieldComponent.VALID, JCFieldComponent.INVALID,
or JCFieldComponent.UNDER_EDITpublic boolean getSelectOnEnter()
getSelectOnEnter in interface JCFieldComponentsetSelectOnEnter(boolean)public void setSelectOnEnter(boolean select)
false.
setSelectOnEnter in interface JCFieldComponentselect - if true, set the selection on entering the fieldpublic void commitEdit()
commitEdit in interface JCFieldComponentpublic boolean isRequired()
true if the field is required.
isRequired in interface JCFieldComponentpublic void setRequired(boolean required)
setRequired in interface JCFieldComponentrequired - if true, this field is requiredpublic void setEditable(boolean b)
setEditable to make sure the background is set to the
correct color immediately (otherwise the setBackground() method
above will intercept the change and nothing will happen until the user tries
to edit the field).
setEditable in class JTextComponentb - if true, the field is editablepublic void setLocale(Locale l)
setLocale in class Componentl - the new locale to be used
|
Copyright © 2004 Quest Software Inc.. All rights reserved. |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||