Obtaining the Login Status
API Description
This API is used to obtain the login status.
Precautions
- This API is an asynchronous API. The return value only indicates whether the API is successfully called. The actual service processing result is returned in the corresponding callback function.
Method Definition
1
|
HWM_SDK_AGENT_API hwmsdk::HwmErrCode GetLoginState(); |
Callback Function
1
|
virtual void OnGetLoginStateResult(hwmsdk::HwmErrCode ret, const char* reason, const HwmLoginStateInfo* loginStateInfo) {}; |
Parameter Description
|
Parameter |
Type |
Description |
|---|---|---|
|
loginState |
HwmLoginState |
Login status. |
|
Enumerated Value |
Description |
|---|---|
|
LOGIN_STATUS_UN_LOGIN |
Logged out. |
|
LOGIN_STATUS_LOGINING |
Logging in. |
|
LOGIN_STATUS_LOGINED |
Logged in. |
|
LOGIN_STATUS_LOGOUTING |
Logging out. |
1 2 3 4 5 6 7 8 9 |
/** * Obtain the login status. */ int demoGetLoginStateDlg::GetLoginState() { // Call the API for obtaining the login status. int ret = hwmsdkagent::GetLoginState(); return ret; } |
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot