|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnextapp.echo.AbstractComponent
net.sf.jzeno.echo.components.CustomComponent
net.sf.jzeno.echo.editor.AbstractNumberEditor
public abstract class AbstractNumberEditor
Nested Class Summary | |
---|---|
class |
AbstractNumberEditor.DefaultValidator
|
Field Summary | |
---|---|
static int |
LEFT
|
protected java.lang.Number |
maximum
|
protected java.lang.Number |
minimum
|
static int |
PERCENT_UNITS
|
static int |
PIXEL_UNITS
|
static int |
RIGHT
|
Constructor Summary | |
---|---|
AbstractNumberEditor()
|
|
AbstractNumberEditor(java.lang.Class beanClass,
java.lang.String propertyName,
java.lang.String constructionHints)
|
Method Summary | |
---|---|
abstract int |
compareTo(java.lang.Number n1,
java.lang.Number n2)
|
abstract java.lang.String |
formatNumber(java.lang.Number number)
|
java.lang.String |
getActionCommand()
|
Color |
getBackground()
Returns the background color of the component. |
int |
getDefaultWidth()
|
int |
getExactLength()
|
Font |
getFont()
Returns the font. |
Color |
getForeground()
Returns the foreground of the component. |
java.lang.String |
getInvalidMessage()
|
java.lang.String |
getInvalidMessageKey()
Deprecated. use getInvalidMessage() instead |
int |
getMaximumLength()
|
java.lang.String |
getNullValue()
|
java.lang.String |
getText()
|
java.lang.String |
getToolTipText()
|
int |
getWidth()
Gets the width of the text field. |
int |
getWidthUnits()
Gets the units in which width is specified. |
abstract java.lang.Number |
getZero()
|
boolean |
isAllowZero()
|
boolean |
isAsync()
|
boolean |
isIncludeMaximum()
|
boolean |
isIncludeMinimum()
|
abstract boolean |
isNumberValid(java.lang.String text)
|
boolean |
isReadOnly()
|
boolean |
isRequired()
Query if the editor is required to be filled in. |
abstract java.lang.Number |
parseNumber(java.lang.String text)
|
void |
propagateEvent(ActionEvent event)
|
void |
rebind()
This operation causes the component to reset it's content to that of the domain model. |
void |
setActionCommand(java.lang.String command)
|
void |
setAlignment(int alignment)
Sets the horizontal text alignment of the input field. |
void |
setAllowZero(boolean allowZero)
|
void |
setAsync(boolean async)
|
void |
setBackground(Color background)
Sets the background color of the component. |
void |
setColumns(int columns)
Deprecated. |
void |
setExactLength(int i)
|
void |
setFocused(boolean focused)
Sets whether the component is focused. |
void |
setFont(Font font)
Sets the font of the component. |
void |
setForeground(Color foreground)
Sets the foreground color of the component. |
void |
setIncludeMaximum(boolean includeMaximum)
|
void |
setIncludeMinimum(boolean includeMinimum)
|
void |
setInvalidMessage(java.lang.String invalidMessage)
|
void |
setInvalidMessageKey(java.lang.String s)
Deprecated. use setInvalidMessage() instead |
void |
setMaximumLength(int i)
|
void |
setNullValue(java.lang.String nullValue)
|
void |
setReadOnly(boolean readOnly)
Mark this component as read-only. |
void |
setRequired(boolean b)
Determine if the editor is required to be filled in. |
void |
setText(java.lang.String text)
|
void |
setToolTipText(java.lang.String toolTipText)
|
void |
setWidth(int width)
Sets the width of the text field. |
void |
setWidthUnits(int units)
Sets the units in which width is specified. |
Methods inherited from class net.sf.jzeno.echo.components.CustomComponent |
---|
addValidator, fireActionEvent, fireActionEvent, fireActionEvent, getBean, getBeanClass, getDecorator, getNullObject, getProperty, getValidationErrors, getValidators, getValue, isBound, isMarkedInvalid, isValid, markInvalid, markValid, preRender, removeValidator, setBean, setBeanClass, setDecorator, setNullObject, setProperty, setValue, traceValue, validate |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface net.sf.jzeno.echo.Precreation |
---|
applyContext |
Field Detail |
---|
public static final int RIGHT
public static final int LEFT
protected java.lang.Number minimum
protected java.lang.Number maximum
public static final int PIXEL_UNITS
public static final int PERCENT_UNITS
Constructor Detail |
---|
public AbstractNumberEditor()
public AbstractNumberEditor(java.lang.Class beanClass, java.lang.String propertyName, java.lang.String constructionHints)
Method Detail |
---|
public void rebind()
RebindableComponent
This operation causes the component to reset it's content to that of the domain model.
rebind
in interface RebindableComponent
rebind
in class CustomComponent
public boolean isAllowZero()
public void setAllowZero(boolean allowZero)
public void setNullValue(java.lang.String nullValue)
public java.lang.String getNullValue()
public java.lang.String getText()
public void setText(java.lang.String text)
public void setFocused(boolean focused)
Component
setFocused
in interface Component
setFocused
in class AbstractComponent
focused
- True if the component is to be focused.public void setColumns(int columns)
Sets the width of the input field. Specified in characters on screen.
public void setWidth(int width)
Sets the width of the text field.
public int getWidth()
Gets the width of the text field.
public void setWidthUnits(int units)
Sets the units in which width is specified.
public int getWidthUnits()
Gets the units in which width is specified.
public void setToolTipText(java.lang.String toolTipText)
public java.lang.String getToolTipText()
public void setForeground(Color foreground)
Component
setForeground
in interface Component
setForeground
in class AbstractComponent
foreground
- The new foreground color of the component.public Color getForeground()
Component
getForeground
in interface Component
getForeground
in class AbstractComponent
public void setBackground(Color background)
Component
setBackground
in interface Component
setBackground
in class AbstractComponent
background
- The new background color of the component.public Color getBackground()
Component
getBackground
in interface Component
getBackground
in class AbstractComponent
public void setReadOnly(boolean readOnly)
PropertyComponent
Mark this component as read-only.
setReadOnly
in interface PropertyComponent
setReadOnly
in class CustomComponent
public boolean isReadOnly()
isReadOnly
in interface PropertyComponent
isReadOnly
in class CustomComponent
public abstract boolean isNumberValid(java.lang.String text)
public abstract java.lang.Number parseNumber(java.lang.String text)
public abstract java.lang.String formatNumber(java.lang.Number number)
public abstract java.lang.Number getZero()
public abstract int compareTo(java.lang.Number n1, java.lang.Number n2)
public int getDefaultWidth()
public boolean isIncludeMaximum()
public void setIncludeMaximum(boolean includeMaximum)
public boolean isIncludeMinimum()
public void setIncludeMinimum(boolean includeMinimum)
public void setMaximumLength(int i)
public int getMaximumLength()
public void setExactLength(int i)
public int getExactLength()
public java.lang.String getInvalidMessage()
public void setInvalidMessage(java.lang.String invalidMessage)
public java.lang.String getInvalidMessageKey()
public void setInvalidMessageKey(java.lang.String s)
public void setRequired(boolean b)
PropertyComponent
Determine if the editor is required to be filled in.
setRequired
in interface PropertyComponent
setRequired
in class CustomComponent
public boolean isRequired()
PropertyComponent
Query if the editor is required to be filled in.
isRequired
in interface PropertyComponent
isRequired
in class CustomComponent
public java.lang.String getActionCommand()
getActionCommand
in interface EventSource
getActionCommand
in class CustomComponent
public void setActionCommand(java.lang.String command)
setActionCommand
in interface EventSource
setActionCommand
in class CustomComponent
public void propagateEvent(ActionEvent event)
propagateEvent
in interface EventPropagator
public boolean isAsync()
public void setAsync(boolean async)
public void setAlignment(int alignment)
alignment
- LEFT
or RIGHT
public void setFont(Font font)
Component
setFont
in interface Component
setFont
in class AbstractComponent
font
- The new font of the component.public Font getFont()
Component
getFont
in interface Component
getFont
in class AbstractComponent
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |