Search in sources :

Example 6 with GroupBean

use of org.qii.weiciyuan.bean.GroupBean in project weiciyuan by qii.

the class CreateGroupDao method create.

public GroupBean create() throws WeiboException {
    String url = URLHelper.GROUP_CREATE;
    Map<String, String> map = new HashMap<String, String>();
    map.put("access_token", access_token);
    map.put("name", name);
    String jsonData = HttpUtility.getInstance().executeNormalTask(HttpMethod.Post, url, map);
    Gson gson = new Gson();
    GroupBean value = null;
    try {
        value = gson.fromJson(jsonData, GroupBean.class);
    } catch (JsonSyntaxException e) {
        AppLogger.e(e.getMessage());
    }
    return value;
}
Also used : JsonSyntaxException(com.google.gson.JsonSyntaxException) HashMap(java.util.HashMap) Gson(com.google.gson.Gson) GroupBean(org.qii.weiciyuan.bean.GroupBean)

Aggregations

GroupBean (org.qii.weiciyuan.bean.GroupBean)6 ArrayList (java.util.ArrayList)4 Gson (com.google.gson.Gson)3 JsonSyntaxException (com.google.gson.JsonSyntaxException)3 HashMap (java.util.HashMap)3 AlertDialog (android.app.AlertDialog)1 DialogInterface (android.content.DialogInterface)1 Intent (android.content.Intent)1 View (android.view.View)1 ImageView (android.widget.ImageView)1 List (java.util.List)1 GroupListBean (org.qii.weiciyuan.bean.GroupListBean)1 MessageListBean (org.qii.weiciyuan.bean.MessageListBean)1 MessageTimeLineData (org.qii.weiciyuan.bean.android.MessageTimeLineData)1 TimeLinePosition (org.qii.weiciyuan.bean.android.TimeLinePosition)1 MyAsyncTask (org.qii.weiciyuan.support.lib.MyAsyncTask)1