Hi ,

 

I guess , when user calls method beanReader.parse(file) , the  ‘update’ of class org.apache.commons.betwixt._expression_.MethodUpdater  gets called.

 

I observed that if the data types are java.util.Date , int the attributes are not getting converted to the required data type and hence I get the InvalidArgumentExcetion as the default attribute type passed is ‘String’

 

If the date is java.sql.Date then there is no problem but if it is java.util.Date type then I get this exception. One possible cause is that these data types do not have constructors accepting String as only argument.

 

e.g java.util.Date  has deprecated new Date(String) constructor.

And the Interger can not be converted to int like  new int(String)  the code

 

“newValue = ConvertUtils.convert( (String) newValue, valueType );”  will always fail to convert to int or java.util.Date.

 

Attaching the log file where I modified MethodUpdater and the log file I got. In theMethodUpdater , I have put some statements with ‘UJ’ so you will see the log has those debug statements.

 

Thanks

Ujjwala

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to