[json-lib-user] java.lang.NoSuchMethodException
Brought to you by:
aalmiray
From: Eric K. <eri...@gm...> - 2012-03-09 21:10:07
|
When I run the following code Server [] servers = (Server[]) JSONArray.toArray(jsonArray, Server.class); // line 1308 I get net.sf.json.JSONException: java.lang.NoSuchMethodException: com.kodak.vip.sct.view.PreferencesDialog$ServerPanel$Server.<init>() at net.sf.json.JSONObject.toBean(JSONObject.java:288) at net.sf.json.JSONArray.toArray(JSONArray.java:318) at net.sf.json.JSONArray.toArray(JSONArray.java:250) at com.kodak.vip.sct.view.PreferencesDialog$ServerPanel$ServerComboBox.<init>(PreferencesDialog.java:1308) So far as I can tell, json-lib thinks it cannot find the no-arg constructor for my Server class. But it is there, I can see it. I have even tested this same line of code in a stand-alone test application and it works fine, but when I am using it in my real application I get this exception. What could be causing json-lib to be confused? Cheers, Eric |