getServerTime
Introduction
Get the live server time.
Do not works on Web.
Parameter details
This API has no parameters
Returned template
V2TimValueCallback<int>
{
code : int
desc : String
data : int // The live time on the server.
}
Return value details
name | type | description |
---|---|---|
code | int | Request result: Error codes. 0 means success. |
desc | String | The description of the error. It will be empty if success. |
data | bool | The live time on the server. |
Code example
V2TimValueCallback<int> getServerTimeRes =
await TencentImSDKPlugin.v2TIMManager.getServerTime();
if (getServerTimeRes.code == 0) {
getServerTimeRes.data;
}