Commit c43e2abe by Kim Jinsung

THETA S端末の時間初期化問題で、Android端末の現在時間は常に設定

parent a180cb68
...@@ -22,8 +22,11 @@ import java.math.RoundingMode; ...@@ -22,8 +22,11 @@ import java.math.RoundingMode;
import java.net.HttpURLConnection; import java.net.HttpURLConnection;
import java.net.MalformedURLException; import java.net.MalformedURLException;
import java.net.URL; import java.net.URL;
import java.text.SimpleDateFormat;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.Arrays; import java.util.Arrays;
import java.util.Date;
import java.util.TimeZone;
import java.util.Timer; import java.util.Timer;
import java.util.TimerTask; import java.util.TimerTask;
...@@ -1111,6 +1114,8 @@ public class HttpConnector { ...@@ -1111,6 +1114,8 @@ public class HttpConnector {
//API2.0 //API2.0
if (mSessionId != null) { if (mSessionId != null) {
parameters.put("sessionId", mSessionId); parameters.put("sessionId", mSessionId);
//THETA S端末の時間初期化問題で、現在時間は常に設定
options.put("dateTimeZone", currentDateTimeZone());
} }
parameters.put("options", options); parameters.put("options", options);
...@@ -1521,4 +1526,12 @@ public class HttpConnector { ...@@ -1521,4 +1526,12 @@ public class HttpConnector {
return isSuccess; return isSuccess;
} }
/**
* yyyy:MM:dd HH:mm:ssXXXフォマットで現在の日付を返す。
* @return 現在の日付
*/
private String currentDateTimeZone() {
return new SimpleDateFormat("yyyy:MM:dd HH:mm:ssXXX").format(new Date());
}
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment