#[non_exhaustive]pub struct Session {
pub user: String,
pub terminal: Option<String>,
pub remote: bool,
pub since: Option<SystemTime>,
}Expand description
A login session.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.user: StringThe user.
terminal: Option<String>The terminal.
remote: boolWhether it is remote. The remote address is not returned.
since: Option<SystemTime>When it started.
Trait Implementations§
impl Eq for Session
impl StructuralPartialEq for Session
Auto Trait Implementations§
impl Forget for Session
impl Freeze for Session
impl Move for Session
impl RefUnwindSafe for Session
impl Send for Session
impl Sync for Session
impl Unpin for Session
impl UnsafeUnpin for Session
impl UnwindSafe for Session
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