pub struct NativeSessionData {
pub session: SessionView,
pub user: FieldValue,
}Expand description
Session data before the selected User value crosses a typed authentication boundary.
Fields§
§session: SessionViewSession passed to the credential writer.
user: FieldValuePreserve the selected User object or relationship array for trusted callbacks.
Implementations§
Source§impl NativeSessionData
impl NativeSessionData
Sourcepub fn user_field(&self, name: &str) -> &FieldValue
pub fn user_field(&self, name: &str) -> &FieldValue
Read a User model field. Relationship arrays have no User model fields.
Sourcepub fn public_user(&self, config: &UserConfig) -> AuthResult<FieldValue>
pub fn public_user(&self, config: &UserConfig) -> AuthResult<FieldValue>
Clone enumerable User fields and remove fields with returned: false.
Arrays become numeric-key objects only at this output boundary.
Trait Implementations§
Source§impl Clone for NativeSessionData
impl Clone for NativeSessionData
Source§impl Debug for NativeSessionData
impl Debug for NativeSessionData
Source§impl From<NativeSessionData> for FieldMap
impl From<NativeSessionData> for FieldMap
Source§fn from(data: NativeSessionData) -> Self
fn from(data: NativeSessionData) -> Self
Converts to this type from the input type.
Source§impl From<SessionData<JoinValue<UserView>>> for NativeSessionData
impl From<SessionData<JoinValue<UserView>>> for NativeSessionData
Source§impl From<SessionData> for NativeSessionData
impl From<SessionData> for NativeSessionData
Source§fn from(data: SessionData) -> Self
fn from(data: SessionData) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for NativeSessionData
impl RefUnwindSafe for NativeSessionData
impl Send for NativeSessionData
impl Sync for NativeSessionData
impl Unpin for NativeSessionData
impl UnsafeUnpin for NativeSessionData
impl UnwindSafe for NativeSessionData
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