org.jtestcase.core.type
Class ComplexTypeConverter

java.lang.Object
  extended by org.jtestcase.core.type.ComplexTypeConverter

public class ComplexTypeConverter
extends java.lang.Object

Converter for complex data types.

Author:
Fausto Lelli $Id: ComplexTypeConverter.java,v 1.4 2005/10/28 19:46:26 faustothegrey Exp $

Constructor Summary
ComplexTypeConverter()
          Standard constructor
 
Method Summary
 java.lang.Object _convertType(AbstractType typeInstance)
          Converts a complex type in an assert or param instance into an object.
 java.lang.Object _convertType(AbstractType typeInstance, java.lang.String type)
          Converts a complex type in an assert or param instance into an object of the given type.
 java.lang.Object convertComplexParam(AbstractType typeInstance, java.lang.String type)
          Converts a complex type in an assert or param instance into an object of the given type.
 void setLocale(java.util.Locale locale)
          Sets the locale for date and time conversions
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ComplexTypeConverter

public ComplexTypeConverter()
Standard constructor

Method Detail

_convertType

public java.lang.Object _convertType(AbstractType typeInstance)
                              throws TypeConversionException,
                                     java.lang.InstantiationException,
                                     java.lang.IllegalAccessException
Converts a complex type in an assert or param instance into an object.

Parameters:
typeInstance - assert or param instance
Returns:
the constructed object
Throws:
TypeConversionException - in case of any errors
java.lang.IllegalAccessException
java.lang.InstantiationException

_convertType

public java.lang.Object _convertType(AbstractType typeInstance,
                                     java.lang.String type)
                              throws TypeConversionException,
                                     java.lang.InstantiationException,
                                     java.lang.IllegalAccessException
Converts a complex type in an assert or param instance into an object of the given type.

Parameters:
typeInstance - assert or param instance
type - type string
Returns:
the constructed object
Throws:
TypeConversionException - in case of any errors
java.lang.IllegalAccessException
java.lang.InstantiationException

convertComplexParam

public java.lang.Object convertComplexParam(AbstractType typeInstance,
                                            java.lang.String type)
                                     throws TypeConversionException,
                                            java.lang.InstantiationException,
                                            java.lang.IllegalAccessException
Converts a complex type in an assert or param instance into an object of the given type.

Parameters:
typeInstance - assert or param instance
type - type string
Returns:
the constructed object
Throws:
TypeConversionException - in case of any errors
java.lang.IllegalAccessException
java.lang.InstantiationException

setLocale

public void setLocale(java.util.Locale locale)
Sets the locale for date and time conversions

Parameters:
locale - the locale