[json-lib-user] Is it possible to force JSONObject.toBean() throw exceptions on cast issues for pri
Brought to you by:
aalmiray
From: Leonard G. <Leo...@ma...> - 2009-04-30 18:08:23
|
Hello, I noticed that if I have a bean that has primitive member with setters and getters and I try to instantiate it from JSON string that has invalid int for that member, EZ Morph is using default value 0 instead of throwing exceptions. I looked at the code of EZMorpth and I could not find an easy way to change that default behavior. I would like to be able to differentiate between invalid value and default value. Is there some easy trick I can use to do so? Thanks Leonard |