| java.lang.Object org.apache.axis2.jaxws.utility.ConvertUtils
ConvertUtils | public class ConvertUtils (Code) | | Provides utilities to convert an object into a different kind of Object. For example, convert a
String[] into a List
|
Method Summary | |
public static Object | convert(Object arg, Class destClass) Utility function to convert an Object to some desired Class.
Normally this is used for T[] to List processing. | public static boolean | isConvertable(Object obj, Class dest) This method should return true if the convert method will succeed. |
convert | public static Object convert(Object arg, Class destClass) throws WebServiceException(Code) | | Utility function to convert an Object to some desired Class.
Normally this is used for T[] to List processing. Other conversions are also done (i.e.
HashMap <->Hashtable, etc.)
Use the isConvertable() method to determine if conversion is possible. Note that any changes
to convert() must also be accompanied by similar changes to isConvertable()
Parameters: arg - the array to convert Parameters: destClass - the actual class we want object of destClass if conversion possible, otherwise returns arg |
isConvertable | public static boolean isConvertable(Object obj, Class dest)(Code) | | This method should return true if the convert method will succeed.
Note that any changes to isConvertable() must also be accompanied by similar changes to
convert()
Parameters: obj - source object or class Parameters: dest - destination class boolean true if convert(..) can convert obj to the destination class |
|
|