Json Classes is removed on Confluence 7.0.+

I noticed that classes below is removed on Confluence 7

c.a.c.json.parser.JSONException c.a.c.json.JSONAction c.a.c.util.http.httpclient.TrustedTokenAuthenticator#getTrustedConnectionStatus(org.apache.commons.httpclient.HttpMethod;) c.a.c.util.http.httpclient.TrustedTokenAuthenticator.TrustedConnectionStatus; c.a.c.json.parser.JSONArray c.a.c.json.parser.JSONString c.a.c.json.parser.JSONTokener

With these docs I found new classes but c.a.c.json.parser.JSONException c.a.c.json.JSONAction still missing:
https://docs.atlassian.com/atlassian-confluence/6.6.0/

I just try to get my xwork actions to work but can not find right interface for Json to get them work.

What to do get them work?

Or do I give up and use Servlet Module instead?

Here is an answerd (I got everything work now):

public class LoadAdmin extends ConfluenceActionSupport implements Beanable {
// some code here
}

 public Object getBean()
    {
    	JsonObject json = new JsonObject()
    	        .setProperty("tasks", tasks)
    	        .setProperty("totalCount", pages)
    	        .setProperty("success", value);
    	
    	Map<String, Object> bean = new HashMap<String, Object>();
    	HashMap<String, Object> jsonHashMap = new Gson().fromJson(json.serialize(), HashMap.class);
    	bean = jsonHashMap;       
    	return bean;
    }
1 Like