|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.sencha.gxt.widget.core.client.form.PropertyEditor<N>
com.sencha.gxt.widget.core.client.form.NumberPropertyEditor<N>
N - the number typepublic abstract class NumberPropertyEditor<N extends java.lang.Number>
A property editor that converts typed numbers to strings and strings back to numbers. Also handles incrementing and decrementing the typed numbers.
| Nested Class Summary | |
|---|---|
static class |
NumberPropertyEditor.BigDecimalPropertyEditor
A number property editor for use with BigDecimal. |
static class |
NumberPropertyEditor.DoublePropertyEditor
A number property editor for use with Double. |
static class |
NumberPropertyEditor.FloatPropertyEditor
A number property editor for use with Float. |
static class |
NumberPropertyEditor.IntegerPropertyEditor
A number property editor for use with Integer. |
static class |
NumberPropertyEditor.LongPropertyEditor
A number property editor for use with Long. |
static class |
NumberPropertyEditor.ShortPropertyEditor
A number property editor for use with Short. |
| Field Summary |
|---|
| Fields inherited from class com.sencha.gxt.widget.core.client.form.PropertyEditor |
|---|
DEFAULT |
| Constructor Summary | |
|---|---|
NumberPropertyEditor(N incrAmount)
Creates a new number property editor with the default number type (Double). |
|
NumberPropertyEditor(NumberFormat format,
N incrAmount)
Creates a new number property editor. |
|
NumberPropertyEditor(java.lang.String pattern,
N incrAmount)
Creates a new number property editor. |
|
| Method Summary | |
|---|---|
N |
decr(N value)
Decrements a value by the current increment amount. |
NumberFormat |
getFormat()
Returns the editor's format. |
N |
getIncrement()
Gets the current increment amount. |
N |
incr(N value)
Increments a value by the current increment amount. |
N |
parse(java.lang.CharSequence text)
|
java.lang.String |
render(java.lang.Number value)
|
void |
setFormat(NumberFormat format)
Sets the editor's format. |
void |
setIncrement(N value)
Sets the increment amount (defaults to zero). |
| Methods inherited from class com.sencha.gxt.widget.core.client.form.PropertyEditor |
|---|
render |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public NumberPropertyEditor(N incrAmount)
public NumberPropertyEditor(NumberFormat format,
N incrAmount)
format - the number format
public NumberPropertyEditor(java.lang.String pattern,
N incrAmount)
pattern - the number format pattern| Method Detail |
|---|
public N decr(N value)
value - the value to decrement
public NumberFormat getFormat()
public N getIncrement()
public N incr(N value)
value - the value to increment
public N parse(java.lang.CharSequence text)
throws java.text.ParseException
java.text.ParseExceptionpublic java.lang.String render(java.lang.Number value)
public void setFormat(NumberFormat format)
format - the formatpublic void setIncrement(N value)
value - the new increment amount
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||