Hi,

Xybrek wrote:

> Hello,
> 
> I'm getting this error when trying to "deserialize":
> 
> Cannot construct MyClass as it does not have a no-args constructor.
> 
> Looking at the docs, it means that Xtream is not running in enhanced mode?
> 
> However, in the same JVM and using the same class the Google Gson
> library can serialize and deserialize objects without problem:
> 
> MyClass c;
> c = (MyClass) new Gson().fromJson(json, MyClass.class);
> 
> So why Xstream can't do to XML what Gson can do for JSON? Is this easy
> to patch in the Xstream code or is this a limitation that is not easy to
> get around with?

XStream will normally run always in enhanced mode. Which version of XStream 
you're using, which Java version and vendor? Is it a special environment 
(e.g. app server or applet)? How did you initialize XStream?

- Jörg


---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply via email to