|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.ibm.as400.ui.framework.java.DataFormatter
com.ibm.as400.ui.framework.java.ShortFormatter
public class ShortFormatter extends DataFormatter
Formatter for exchanging Short values between
DataBeans and user interface components.
If parsing is unsuccessful, an IllegalUserDataException is thrown.
DataFormatter,
IllegalUserDataException| Constructor and Description |
|---|
ShortFormatter(short minValue,
short maxValue)
Constructs a ShortFormatter. |
| Modifier and Type | Method and Description |
|---|---|
String |
format(Object obj)
Format a number as an integer based on the current locale Throws an IllegalArgumentException if the object is not an instance of Short. |
String |
format(short number)
Format an short number based on the current locale |
Object |
parse(String source)
Parses a string to produce a Short object. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ShortFormatter(short minValue,
short maxValue)
ShortFormatter.
minValue - the minimum value requiredmaxValue - the maximum value required| Method Detail |
|---|
public Object parse(String source)
throws IllegalUserDataException
Short object.
Throws an IllegalUserDataException if parsing fails.
parse in class DataFormattersource - the string to be parsedIllegalUserDataExceptionpublic String format(short number)
number - a valid short number.public String format(Object obj)
format in class DataFormatterobj - a valid Short object cast as an object.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||