|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
Interface for a type convertor. A type convertor converts a Java object from one type to another. A type convertor implementation is required for each type of conversion.
| Method Summary | |
java.lang.Object |
clone()
Creates and returns a copy of this object. |
void |
configure(org.castor.core.util.Configuration configuration)
Configure the converter with given configuration. |
java.lang.Object |
convert(java.lang.Object object)
Convert the object from one type to another. |
java.lang.Class |
fromType()
Get the type being converted from. |
void |
parameterize(java.lang.String parameter)
Initialize the converter with the given parameter. |
java.lang.Class |
toType()
Get the type being converted to. |
| Method Detail |
public void configure(org.castor.core.util.Configuration configuration)
configuration - Configuration to use.public void parameterize(java.lang.String parameter)
null which both should lead to
the default behaviour of the converter.
parameter - The parameter for the convertor (null if is not specified).public java.lang.Object clone()
public java.lang.Class fromType()
public java.lang.Class toType()
public java.lang.Object convert(java.lang.Object object)
throws java.lang.ClassCastException
convert in interface org.exolab.castor.mapping.TypeConvertorobject - The object to convert.
java.lang.ClassCastException - The object is not of the type supported by this convertor.
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||