The only way i see is to change source code in beanutils(may be writing
custom converter or catching the conversionexception etc.,) and recompile
it. I 'd appreciate if you can let me know if there is any graceful way to
handle this requirement.
thanks.
akira
akiraleon123 wrote:
>
> Hi All,
> Any help is sincerely appreciated.
>
> How can i instruct digester to ignore the data type mismatch exceptions
> being caused by beanutils and proceed further?
> So, from the previous xml file, though the first resource causes an
> exception,
>
>
> org.apache.commons.beanutils.ConversionException: For input string: "fcd"
> at
> org.apache.commons.beanutils.converters.BigDecimalConverter.convert(BigDecimalConverter.java:162)
>
>
>
> i want to get the second resource object.
>
>
> <country>
> <companies>
> <company name="dell">
> <resources>
>
> <resource value="fcd"/> <!--data type mismatch-->
>
> <resource value="33.44"/>
>
> </resources>
> </company>
> </companies>
> </country>
>
>
> My class file:
>
> class Resource{
> private BigDecimal value;
> //getters, setters
> }
>
>
>
> thanks,
> akira.
>
>
--
View this message in context:
http://www.nabble.com/digester-ignore-data-mismatch-exception--tf4839300.html#a13863883
Sent from the Commons - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]