ADD file via upload

master
prw4s76gk 11 months ago
parent 65e58d061f
commit c6f9708563

@ -0,0 +1,767 @@
/**
* @ProiectName:MiNote
* @Package: gtask.remote
* @ClassName: GTaskAClient
* @Description: GTaskGoogle Tasks API使便使Google Tasks
* @Author: wmq
*/
package net.micode.notes.gtask.remote;
//以下内容为引入Android中的各个类
import android.accounts.Account;//引入Android中的Account类代表一个用户账户
import android.accounts.AccountManager;//引入Android中的AccountManager类提供了管理用户账户的一些方法
import android.accounts.AccountManagerFuture;
import android.app.Activity;
import android.os.Bundle;
import android.text.TextUtils;
import android.util.Log;
import net.micode.notes.gtask.data.Node;
import net.micode.notes.gtask.data.Task;
import net.micode.notes.gtask.data.TaskList;
import net.micode.notes.gtask.exception.ActionFailureException;
import net.micode.notes.gtask.exception.NetworkFailureException;
import net.micode.notes.tool.GTaskStringUtils;
import net.micode.notes.ui.NotesPreferenceActivity;
import org.apache.http.HttpEntity;
import org.apache.http.HttpResponse;
import org.apache.http.client.ClientProtocolException;
import org.apache.http.client.entity.UrlEncodedFormEntity;
import org.apache.http.client.methods.HttpGet;
import org.apache.http.client.methods.HttpPost;
import org.apache.http.cookie.Cookie;
import org.apache.http.impl.client.BasicCookieStore;
import org.apache.http.impl.client.DefaultHttpClient;
import org.apache.http.message.BasicNameValuePair;
import org.apache.http.params.BasicHttpParams;
import org.apache.http.params.HttpConnectionParams;
import org.apache.http.params.HttpParams;
import org.apache.http.params.HttpProtocolParams;
import org.json.JSONArray;
import org.json.JSONException;
import org.json.JSONObject;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.util.LinkedList;
import java.util.List;
import java.util.zip.GZIPInputStream;
import java.util.zip.Inflater;
import java.util.zip.InflaterInputStream;
/**
* @: GTaskClient
* @: GTaskClient
* @: 使GTaskClient
* @Author: wmq
*/
public class GTaskClient {
private static final String TAG = GTaskClient.class.getSimpleName();//TAG是一个常量字符串用于在日志输出中标识GTaskClient类。
private static final String GTASK_URL = "https://mail.google.com/tasks/";
private static final String GTASK_GET_URL = "https://mail.google.com/tasks/ig";
private static final String GTASK_POST_URL = "https://mail.google.com/tasks/r/ig";
private static GTaskClient mInstance = null;
private DefaultHttpClient mHttpClient;
private String mGetUrl;
private String mPostUrl;
private long mClientVersion;
private boolean mLoggedin;
private long mLastLoginTime;
private int mActionId;
private Account mAccount;
private JSONArray mUpdateArray;
/**
* @: GTaskClient()
* @: GTaskClient
* @:
* @Author: wmq
*/
private GTaskClient() {
mHttpClient = null; //将mHttpClient初始化为null表示初始情况下没有可用的HTTP客户端。
mGetUrl = GTASK_GET_URL;
mPostUrl = GTASK_POST_URL;
mClientVersion = -1; //将mClientVersion初始化为-1表示客户端版本号未知。
mLoggedin = false; //将mLoggedin初始化为false表示当前未登录状态。
mLastLoginTime = 0; //将mLastLoginTime初始化为0表示上次登录时间为初始状态。
mActionId = 1;
mAccount = null;
mUpdateArray = null;
}
/**
* @:getInstance
* @ :mInstance
* @:
* @: 使getInstance(),mInstance
* @Author: wmq
*/
public static synchronized GTaskClient getInstance() {
if (mInstance == null) {
mInstance = new GTaskClient();
}
return mInstance;
}
/**
* @: login
* @ : activity
* @: Google TasksTokenURL
* @: ,
*
* @Author: wmq
*/
public boolean login(Activity activity) {
// we suppose that the cookie would expire after 5 minutes
// then we need to re-login
final long interval = 1000 * 60 * 5;
if (mLastLoginTime + interval < System.currentTimeMillis()) {
mLoggedin = false;
}
// need to re-login after account switch
if (mLoggedin
&& !TextUtils.equals(getSyncAccount().name, NotesPreferenceActivity
.getSyncAccountName(activity))) {
mLoggedin = false;
}
if (mLoggedin) {
Log.d(TAG, "already logged in");
return true;
}
mLastLoginTime = System.currentTimeMillis();
String authToken = loginGoogleAccount(activity, false);//进行账户登录获取授权Token。
if (authToken == null) {
Log.e(TAG, "login google account failed");
return false;
}
// login with custom domain if necessary
if (!(mAccount.name.toLowerCase().endsWith("gmail.com") || mAccount.name.toLowerCase()
.endsWith("googlemail.com"))) {
StringBuilder url = new StringBuilder(GTASK_URL).append("a/");
int index = mAccount.name.indexOf('@') + 1;
String suffix = mAccount.name.substring(index);
url.append(suffix + "/");
mGetUrl = url.toString() + "ig";
mPostUrl = url.toString() + "r/ig";
if (tryToLoginGtask(activity, authToken)) {
mLoggedin = true;
}
}
// try to login with google official url
/**
*googleURL
*mLoggedintrue
*/
if (!mLoggedin) {
mGetUrl = GTASK_GET_URL;
mPostUrl = GTASK_POST_URL;
if (!tryToLoginGtask(activity, authToken)) {
return false;
}
}
mLoggedin = true;//将登录状态设置为true并返回true表示登录成功。
return true;
}
/**
* @: loginGoogleAccount
* @ : activity()/invalidateToken
* @: GoogleToken
* @: AccountManager
* "com.google"
* Googlenull
*
*
* mAccountnull
* getAuthTokenToken
* accountManagerFuture.getResult()TokenauthToken
* loginGoogleAccount(activity, false)Token
* TokenauthTokennull
* Token
* @Author: wmq
*/
private String loginGoogleAccount(Activity activity, boolean invalidateToken) {
String authToken;
AccountManager accountManager = AccountManager.get(activity);//获取系统对象
Account[] accounts = accountManager.getAccountsByType("com.google");//获取类型为"com.google"账户
if (accounts.length == 0) {
Log.e(TAG, "there is no available google account");//打印错误信息
return null;
}
String accountName = NotesPreferenceActivity.getSyncAccountName(activity);//获取要同步的账户名称
Account account = null;
for (Account a : accounts) { //遍历所有账户,找到与要同步的账户名称匹配的账户对象。
if (a.name.equals(accountName)) {
account = a;
break;
}
}
if (account != null) {
mAccount = account;
} else {
Log.e(TAG, "unable to get an account with the same name in the settings");
return null;
}
// get the token now
AccountManagerFuture<Bundle> accountManagerFuture = accountManager.getAuthToken(account,
"goanna_mobile", null, activity, null, null);
//"goanna_mobile"是用于访问Google服务的令牌类型
try {
Bundle authTokenBundle = accountManagerFuture.getResult();
authToken = authTokenBundle.getString(AccountManager.KEY_AUTHTOKEN);
if (invalidateToken) {
accountManager.invalidateAuthToken("com.google", authToken);
loginGoogleAccount(activity, false);
}
} catch (Exception e) { //捕获可能发生的异常
Log.e(TAG, "get auth token failed");//打印错误信息
authToken = null;
}
return authToken;
}
/**
* @: tryToLoginGtask
* @ : activity() / authToken
* @: 使TokenGoogleGTask
* @: tryToLoginGtaskloginGtask使TokenGTask
* TokenTokenGTask
* @Author: wmq
*/
private boolean tryToLoginGtask(Activity activity, String authToken) {
if (!loginGtask(authToken)) {
// maybe the auth token is out of date, now let's invalidate the
// token and try again
authToken = loginGoogleAccount(activity, true);
if (authToken == null) {
Log.e(TAG, "login google account failed");
return false;
}
if (!loginGtask(authToken)) {
Log.e(TAG, "login gtask failed");
return false;
}
}
return true;
}
/**
* @: loginGtask
* @ : authToken
* @: GoogleGTask
* @:
* TokenURL
* Cookie"GTL"Cookie
*
* @Author: wmq
*/
//创建了一个DefaultHttpClient对象并设置了一些Http参数
private boolean loginGtask(String authToken) {
int timeoutConnection = 10000;
int timeoutSocket = 15000;
HttpParams httpParameters = new BasicHttpParams();
HttpConnectionParams.setConnectionTimeout(httpParameters, timeoutConnection);
HttpConnectionParams.setSoTimeout(httpParameters, timeoutSocket);
mHttpClient = new DefaultHttpClient(httpParameters);
BasicCookieStore localBasicCookieStore = new BasicCookieStore();
mHttpClient.setCookieStore(localBasicCookieStore);
HttpProtocolParams.setUseExpectContinue(mHttpClient.getParams(), false);
// login gtask
//创建一个HttpGet对象并使用mHttpClient.execute(httpGet)发送请求,获取响应
try {
String loginUrl = mGetUrl + "?auth=" + authToken;
HttpGet httpGet = new HttpGet(loginUrl);
HttpResponse response = null;
response = mHttpClient.execute(httpGet);
// get the cookie now
List<Cookie> cookies = mHttpClient.getCookieStore().getCookies();
boolean hasAuthCookie = false;
for (Cookie cookie : cookies) {
if (cookie.getName().contains("GTL")) {
hasAuthCookie = true;
}
}
if (!hasAuthCookie) { //检查是否存在名为"GTL"的认证Cookie
Log.w(TAG, "it seems that there is no auth cookie");
}
// get the client version
//查找特定字符串来获取JavaScript代码块并将其解析为JSON对象从中提取客户端版本号
String resString = getResponseContent(response.getEntity());
String jsBegin = "_setup(";
String jsEnd = ")}</script>";
int begin = resString.indexOf(jsBegin);
int end = resString.lastIndexOf(jsEnd);
String jsString = null;
if (begin != -1 && end != -1 && begin < end) {
jsString = resString.substring(begin + jsBegin.length(), end);
}
JSONObject js = new JSONObject(jsString);
mClientVersion = js.getLong("v");
} catch (JSONException e) {
Log.e(TAG, e.toString());
e.printStackTrace();
return false; //执行过程出现了异常
} catch (Exception e) {
// simply catch all exceptions
Log.e(TAG, "httpget gtask_url failed");//打印错误信息
return false; //执行过程出现了异常
}
return true; //返回true表示登录成功
}
/**
* @: getActionId
* @: ,
* @: getActionId()mActionId1
* @Author: wmq
*/
private int getActionId() {
return mActionId++;
}
/**
* @: createHttpPost
* @: HttpPost
* @: HttpPostURLmPostUrl
* Content-Type,httpPost
* @Author: wmq
*/
private HttpPost createHttpPost() {
HttpPost httpPost = new HttpPost(mPostUrl);
httpPost.setHeader("Content-Type", "application/x-www-form-urlencoded;charset=utf-8");
httpPost.setHeader("AT", "1"); //设置了一个名为AT的请求头并将值设置为1
return httpPost;
}
/**
* @: getResponseContent
* @ : HttpEntity entity
* @: HttpEntity
* @: HttpEntity,InputStreamReaderBufferedReader
*
* @Author: wmq
*/
private String getResponseContent(HttpEntity entity) throws IOException {
String contentEncoding = null;
if (entity.getContentEncoding() != null) {
contentEncoding = entity.getContentEncoding().getValue();
Log.d(TAG, "encoding: " + contentEncoding);
}
/**
* "gzip"使GZIPInputStream
* "deflate"使InflaterInputStream
*/
InputStream input = entity.getContent();
if (contentEncoding != null && contentEncoding.equalsIgnoreCase("gzip")) {
input = new GZIPInputStream(entity.getContent());
} else if (contentEncoding != null && contentEncoding.equalsIgnoreCase("deflate")) {
Inflater inflater = new Inflater(true);
input = new InflaterInputStream(entity.getContent(), inflater);
}
try {
InputStreamReader isr = new InputStreamReader(input);
BufferedReader br = new BufferedReader(isr);
StringBuilder sb = new StringBuilder();
while (true) {
String buff = br.readLine();
if (buff == null) {
return sb.toString();
}
//返回拼接后的字符串作为响应内容
sb = sb.append(buff);
}
} finally {
input.close();//在处理完响应内容后,确保关闭了输入流,以释放资源。
}
}
/**
* @: postRequest
* @ : JSONObject js
* @: POSTJSONObject
* @: HttpPost,JSON
* 0BasicNameValuePair,POST
* @Author: wmq
*/
private JSONObject postRequest(JSONObject js) throws NetworkFailureException {
if (!mLoggedin) {
Log.e(TAG, "please login first");//如果没有登录则抛出ActionFailureException异常并提示用户需要先登录
throw new ActionFailureException("not logged in");
}
HttpPost httpPost = createHttpPost();//创建一个HttpPost对象
try {//设置请求头等参数
LinkedList<BasicNameValuePair> list = new LinkedList<BasicNameValuePair>();
list.add(new BasicNameValuePair("r", js.toString()));
UrlEncodedFormEntity entity = new UrlEncodedFormEntity(list, "UTF-8");
httpPost.setEntity(entity);
//将JSON格式的数据放入一个BasicNameValuePair列表中并将列表转换为UrlEncodedFormEntity实体。
// execute the post
HttpResponse response = mHttpClient.execute(httpPost);
String jsString = getResponseContent(response.getEntity());//将响应实体转换为字符串格式
return new JSONObject(jsString);
} catch (ClientProtocolException e) {//如果发生错误,则打印出对应的问题
Log.e(TAG, e.toString());
e.printStackTrace();
throw new NetworkFailureException("postRequest failed");
} catch (IOException e) {
Log.e(TAG, e.toString());
e.printStackTrace();
throw new NetworkFailureException("postRequest failed");
} catch (JSONException e) {
Log.e(TAG, e.toString());
e.printStackTrace();
throw new ActionFailureException("unable to convert response content to jsonobject");
} catch (Exception e) {
Log.e(TAG, e.toString());
e.printStackTrace();
throw new ActionFailureException("error occurs when posting request");
}
}
/**
* @: createTask
* @ : Task task
* @:
* @: commitUpdate(),JSONObject,postRequest(jsPost)POST,
* IDtask
* @Author: wmq
*/
public void createTask(Task task) throws NetworkFailureException {
commitUpdate();
try {
JSONObject jsPost = new JSONObject();
JSONArray actionList = new JSONArray();
// action_list
actionList.put(task.getCreateAction(getActionId()));
jsPost.put(GTaskStringUtils.GTASK_JSON_ACTION_LIST, actionList);
// client_version
//将actionList放入jsPost中并添加客户端版本信息
jsPost.put(GTaskStringUtils.GTASK_JSON_CLIENT_VERSION, mClientVersion);
// post
JSONObject jsResponse = postRequest(jsPost);//向服务器发送POST请求并获取服务器返回的响应
JSONObject jsResult = (JSONObject) jsResponse.getJSONArray(
GTaskStringUtils.GTASK_JSON_RESULTS).get(0);
task.setGid(jsResult.getString(GTaskStringUtils.GTASK_JSON_NEW_ID));
} catch (JSONException e) { //如果在处理过程中出现JSONException异常则会捕获并打印日志
Log.e(TAG, e.toString());
e.printStackTrace();
throw new ActionFailureException("create task: handing jsonobject failed");
}
}
/**
* @: createTaskList.NetworkFailureException
* @ : TaskList tasklist
* @:
* @: commitUpdate(), JSONObject, tasklist.getCreateAction(getActionId())
* ,IDtasklist
* @Author: wmq
*/
public void createTaskList(TaskList tasklist) throws NetworkFailureException {
commitUpdate();
try {
JSONObject jsPost = new JSONObject();
JSONArray actionList = new JSONArray();
// action_list
actionList.put(tasklist.getCreateAction(getActionId()));
jsPost.put(GTaskStringUtils.GTASK_JSON_ACTION_LIST, actionList);
// client version
//将actionList放入jsPost中并添加客户端版本信息
jsPost.put(GTaskStringUtils.GTASK_JSON_CLIENT_VERSION, mClientVersion);
// post
//调用postRequest(jsPost)方法向服务器发送POST请求并获取服务器返回的响应
JSONObject jsResponse = postRequest(jsPost);
JSONObject jsResult = (JSONObject) jsResponse.getJSONArray(
GTaskStringUtils.GTASK_JSON_RESULTS).get(0);
tasklist.setGid(jsResult.getString(GTaskStringUtils.GTASK_JSON_NEW_ID));
} catch (JSONException e) { //处理过程中出现JSONException异常则会捕获并打印日志并抛出ActionFailureException异常表示处理JSON对象失败
Log.e(TAG, e.toString());
e.printStackTrace();
throw new ActionFailureException("create tasklist: handing jsonobject failed");
}
}
/**
* @: NetworkFailureException
* @:
* @Author: wmq
*/
public void commitUpdate() throws NetworkFailureException {
if (mUpdateArray != null) {
try {
JSONObject jsPost = new JSONObject();
/**
* mUpdateArrayJSONObjectjsPost
* mUpdateArrayjsPost
*/
// action_list
jsPost.put(GTaskStringUtils.GTASK_JSON_ACTION_LIST, mUpdateArray);
// client_version
jsPost.put(GTaskStringUtils.GTASK_JSON_CLIENT_VERSION, mClientVersion);
postRequest(jsPost);//向服务器发送POST请求将更新的任务数据提交到服务器进行处理
mUpdateArray = null;//mUpdateArray设置为null表示已经提交了所有的任务更新操作
} catch (JSONException e) { //处理过程中出现JSONException异常则会捕获并打印日志
Log.e(TAG, e.toString());
e.printStackTrace();
throw new ActionFailureException("commit update: handing jsonobject failed");
}
}
}
/**
* @: NetworkFailureException
* @ : Node node
* @:
* @Author: wmq
*/
public void addUpdateNode(Node node) throws NetworkFailureException {
if (node != null) {
// too many update items may result in an error
// set max to 10 items
/**
* nodemUpdateArray,
* commitUpdate()
*/
if (mUpdateArray != null && mUpdateArray.length() > 10) {
commitUpdate();
}
if (mUpdateArray == null)//如果mUpdateArray仍然为空那么它会创建一个JSONArray对象mUpdateArray用于存储任务更新操作
mUpdateArray = new JSONArray();
mUpdateArray.put(node.getUpdateAction(getActionId()));//获取节点的更新操作并将其添加到mUpdateArray中
}
}
/**
* @: moveTask
* @ : task, preParent, curParent
* @:
* @: jsPost
* @Author: wmq
*/
/**
* commitUpdate()
*/
public void moveTask(Task task, TaskList preParent, TaskList curParent)
throws NetworkFailureException {
commitUpdate();
/**
* JSONArrayactionList
* JSONObjectaction
*/
try {
JSONObject jsPost = new JSONObject();
JSONArray actionList = new JSONArray();
JSONObject action = new JSONObject();
// action_list
//在action中它设置了以下属性
action.put(GTaskStringUtils.GTASK_JSON_ACTION_TYPE,
GTaskStringUtils.GTASK_JSON_ACTION_TYPE_MOVE);
action.put(GTaskStringUtils.GTASK_JSON_ACTION_ID, getActionId());
action.put(GTaskStringUtils.GTASK_JSON_ID, task.getGid());
if (preParent == curParent && task.getPriorSibling() != null) {
// put prioring_sibing_id only if moving within the tasklist and
// it is not the first one
action.put(GTaskStringUtils.GTASK_JSON_PRIOR_SIBLING_ID, task.getPriorSibling());
}
action.put(GTaskStringUtils.GTASK_JSON_SOURCE_LIST, preParent.getGid());
action.put(GTaskStringUtils.GTASK_JSON_DEST_PARENT, curParent.getGid());
if (preParent != curParent) {
// put the dest_list only if moving between tasklists
action.put(GTaskStringUtils.GTASK_JSON_DEST_LIST, curParent.getGid());
}
//将action添加到actionList中并将actionList添加到jsPost中
actionList.put(action);
jsPost.put(GTaskStringUtils.GTASK_JSON_ACTION_LIST, actionList);
// client_version
jsPost.put(GTaskStringUtils.GTASK_JSON_CLIENT_VERSION, mClientVersion);
postRequest(jsPost);
} catch (JSONException e) { //如果在处理过程中出现JSONException异常则会捕获并打印日志
Log.e(TAG, e.toString());
e.printStackTrace();
throw new ActionFailureException("move task: handing jsonobject failed");
}
}
/**
* @: deleteNode
* @ : node
* @: Node
* @: JSONObject
* jsPostmUpdateArraynull
* @Author: wmq
*/
public void deleteNode(Node node) throws NetworkFailureException {
commitUpdate();
try {
JSONObject jsPost = new JSONObject();
JSONArray actionList = new JSONArray();
// action_list
/**
* nodedeletedtrue
* node.getUpdateAction(getActionId())JSONObjectactionList
*/
node.setDeleted(true);
actionList.put(node.getUpdateAction(getActionId()));
jsPost.put(GTaskStringUtils.GTASK_JSON_ACTION_LIST, actionList);
// client_version
jsPost.put(GTaskStringUtils.GTASK_JSON_CLIENT_VERSION, mClientVersion);
/**
* jsPostpostRequest(jsPost)POST
* JSONException
* ActionFailureExceptionJSON
*/
postRequest(jsPost);
mUpdateArray = null;
} catch (JSONException e) {
Log.e(TAG, e.toString());
e.printStackTrace();
throw new ActionFailureException("delete node: handing jsonobject failed");
}
}
/**
* @: getTaskLists
* @ : mLoggedin
* @: Task Lists
* @: HttpGetGET,HttpResponse
* JSONObjectjs
* js"t"GTaskStringUtils.GTASK_JSON_LISTS
* @Author: wmq
*/
public JSONArray getTaskLists() throws NetworkFailureException {
if (!mLoggedin) {
Log.e(TAG, "please login first");
throw new ActionFailureException("not logged in");
}
try {
HttpGet httpGet = new HttpGet(mGetUrl);
HttpResponse response = null;
response = mHttpClient.execute(httpGet);
// get the task list
String resString = getResponseContent(response.getEntity());
String jsBegin = "_setup(";
String jsEnd = ")}</script>";
int begin = resString.indexOf(jsBegin);
int end = resString.lastIndexOf(jsEnd);
String jsString = null;
if (begin != -1 && end != -1 && begin < end) {
jsString = resString.substring(begin + jsBegin.length(), end);
}
JSONObject js = new JSONObject(jsString);
return js.getJSONObject("t").getJSONArray(GTaskStringUtils.GTASK_JSON_LISTS);
} catch (ClientProtocolException e) {
Log.e(TAG, e.toString());
e.printStackTrace();
throw new NetworkFailureException("gettasklists: httpget failed");
} catch (IOException e) {
Log.e(TAG, e.toString());
e.printStackTrace();
throw new NetworkFailureException("gettasklists: httpget failed");
} catch (JSONException e) {
Log.e(TAG, e.toString());
e.printStackTrace();
throw new ActionFailureException("get task lists: handing jasonobject failed");
}
}
/**
* @: getTaskList
* @ :listGid
* @: Task List
* @: jsPostPOST
* "tasks"
* @Author: wmq
*/
public JSONArray getTaskList(String listGid) throws NetworkFailureException {
commitUpdate();
try {
JSONObject jsPost = new JSONObject();
JSONArray actionList = new JSONArray();
JSONObject action = new JSONObject();
// action_list
action.put(GTaskStringUtils.GTASK_JSON_ACTION_TYPE,
GTaskStringUtils.GTASK_JSON_ACTION_TYPE_GETALL);
action.put(GTaskStringUtils.GTASK_JSON_ACTION_ID, getActionId());
action.put(GTaskStringUtils.GTASK_JSON_LIST_ID, listGid);
action.put(GTaskStringUtils.GTASK_JSON_GET_DELETED, false);
actionList.put(action);
jsPost.put(GTaskStringUtils.GTASK_JSON_ACTION_LIST, actionList);
// client_version
jsPost.put(GTaskStringUtils.GTASK_JSON_CLIENT_VERSION, mClientVersion);
JSONObject jsResponse = postRequest(jsPost);//将actionList添加到jsPost中
return jsResponse.getJSONArray(GTaskStringUtils.GTASK_JSON_TASKS);
//将客户端版本信息添加到jsPost中并调用postRequest(jsPost)方法向服务器发送POST请求将获取任务列表的操作提交到服务器进行处理。
} catch (JSONException e) {
Log.e(TAG, e.toString());
e.printStackTrace();
throw new ActionFailureException("get task list: handing jsonobject failed");
}
}
/**
* @: getSyncAccount
* @:
* @Author: wmq
*/
public Account getSyncAccount() {
return mAccount;
}
/**
* @: resetUpdateArray
* @:
* @: resetUpdateArray()mUpdateArraynull
*
* @Author: wmq
*/
public void resetUpdateArray() {
mUpdateArray = null;
}
}
Loading…
Cancel
Save