io.gitee.huangguiming.Imcode.utils.IMGsonResponsesBuilder Maven / Gradle / Ivy
package io.gitee.huangguiming.Imcode.utils;
import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
import io.gitee.huangguiming.Imcode.adapter.IMCreateGroupsResponseAdapter;
import io.gitee.huangguiming.Imcode.adapter.IMGetAllGroupResponsesAdapter;
import io.gitee.huangguiming.Imcode.responses.IMCreateGroupResponse;
import io.gitee.huangguiming.Imcode.responses.IMGetAllGroupResponses;
public class IMGsonResponsesBuilder {
private static final GsonBuilder INSTANCE = new GsonBuilder();
static {
INSTANCE.registerTypeAdapter(IMCreateGroupResponse.class,new IMCreateGroupsResponseAdapter());
INSTANCE.registerTypeAdapter(IMGetAllGroupResponses.class,new IMGetAllGroupResponsesAdapter());
}
public static Gson create() {
return INSTANCE.create();
}
}