pub struct LoginState {Show 14 fields
pub password_type: String,
pub extern_password_type: String,
pub history_login_flag: String,
pub state: LoginStatus,
pub guide_modify_pwd_page_flag: String,
pub rsa_padding_type: String,
pub accounts_number: String,
pub wifi_pwd_same_with_web_pwd: String,
pub remain_wait_time: String,
pub lock_status: LockStatus,
pub force_skip_guide: String,
pub username: String,
pub first_login: String,
pub user_level: String,
}Expand description
Login state response from /api/user/state-login
Fields§
§password_type: StringPassword encoding type (0=BASE64, 3=BASE64_after_change, 4=SHA256)
extern_password_type: StringExternal password type
history_login_flag: StringHistory login flag
state: LoginStatusCurrent login state (-1=not_logged_in, 0=logged_in, -2=repeat_login_required)
guide_modify_pwd_page_flag: StringGuide modify password page flag
rsa_padding_type: StringRSA padding type
accounts_number: StringNumber of accounts
wifi_pwd_same_with_web_pwd: StringWiFi password same with web password
remain_wait_time: StringRemaining wait time
lock_status: LockStatusLock status (0=unlocked, >0=locked)
force_skip_guide: StringForce skip guide
username: StringUsername
first_login: StringFirst login flag
user_level: StringUser level
Implementations§
Source§impl LoginState
impl LoginState
Sourcepub fn is_logged_in(&self) -> bool
pub fn is_logged_in(&self) -> bool
Check if user is currently logged in
Sourcepub fn password_encoding(&self) -> PasswordEncoding
pub fn password_encoding(&self) -> PasswordEncoding
Get password encoding type
Trait Implementations§
Source§impl Clone for LoginState
impl Clone for LoginState
Source§fn clone(&self) -> LoginState
fn clone(&self) -> LoginState
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for LoginState
impl Debug for LoginState
Source§impl<'de> Deserialize<'de> for LoginState
impl<'de> Deserialize<'de> for LoginState
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for LoginState
impl RefUnwindSafe for LoginState
impl Send for LoginState
impl Sync for LoginState
impl Unpin for LoginState
impl UnsafeUnpin for LoginState
impl UnwindSafe for LoginState
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more