|
SWIXML 1.5 (#144) |
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.swixml.converters.PrimitiveConverter
The PrimitiveConverter class defines a converter that creates primitive objects (wrapper),
based on a provided input Class and String.
ConverterLibrary| Field Summary | |
static Class |
TEMPLATE
converter's return type |
| 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 org.swixml.converters.InputEvent |
ALT_DOWN_MASK, ALT_GRAPH_DOWN_MASK, ALT_GRAPH_MASK, ALT_MASK, BUTTON1_DOWN_MASK, BUTTON1_MASK, BUTTON2_DOWN_MASK, BUTTON2_MASK, BUTTON3_DOWN_MASK, BUTTON3_MASK, CTRL_DOWN_MASK, CTRL_MASK, JDK_1_3_MODIFIERS, META_DOWN_MASK, META_MASK, SHIFT_DOWN_MASK, SHIFT_MASK |
| Constructor Summary | |
PrimitiveConverter()
|
|
| Method Summary | |
static void |
addConstantProvider(Class type)
Adds a new class or interface to the dictionary of primitive providers. |
static Object |
conv(Class type,
Attribute attr,
Localizer localizer)
Converts String into java primitive type |
Object |
convert(Class type,
Attribute attr,
Localizer localizer)
Converts String into java primitive type |
Class |
convertsTo()
A Converters conversTo method informs about the Class type the converter
is returning when its convert method is called |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final Class TEMPLATE
| Constructor Detail |
public PrimitiveConverter()
| Method Detail |
public static Object conv(Class type,
Attribute attr,
Localizer localizer)
throws Exception
type - Class target typeattr - Attribute value field needs to provide convertable String
Object primitive wrapped into wrapper object
Exception
public Object convert(Class type,
Attribute attr,
Localizer localizer)
throws Exception
convert in interface Convertertype - Class target typeattr - Attribute value field needs to provide convertable String
Object primitive wrapped into wrapper object
Exceptionpublic Class convertsTo()
Converters conversTo method informs about the Class type the converter
is returning when its convert method is called
convertsTo in interface ConverterClass - the Class the converter is returning when its convert method is calledpublic static void addConstantProvider(Class type)
type - Class providing primitive constants / public (final) fields
|
SWIXML 1.5 (#144) |
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||