Android

XStream ConversionException: Cannot construct it does not have a no-args constructor

Hi Guys, While using XStream to parse XML in my app, I see app crash due to this parse issue as ConversionException

Caused by: com.thoughtworks.xstream.converters.ConversionException: Cannot construct <ClassName> as it does not have a no-args constructor : Cannot construct <ClassName> as it does not have a no-args constructor

I see the issue is due to inner class, which i used to call in Main class. And solution for it is remove that inner class code and Create new file with that ClassName. And use this newly created class in Main class. Fixes the issue.

I see tip of information here

Hope it helps somebody.

Leave a Reply

Your email address will not be published. Required fields are marked *