pub enum AuthEvent {
BeforeRegister,
AfterRegister,
BeforeLogin,
AfterLogin,
BeforeApiKey,
AfterApiKey,
}Expand description
One point in an auth endpoint’s lifecycle at which a function may run.
These are declared in the user model’s ordinary [hooks] section, next to
its CRUD hooks, and are only meaningful there — the built-in endpoints are
the user resource’s other door. They sit alongside the HookEvents
rather than replacing them: registration is still a create on user, so
before_create / after_create fire there too.
Variants§
Implementations§
Trait Implementations§
impl Copy for AuthEvent
impl Eq for AuthEvent
Source§impl Ord for AuthEvent
impl Ord for AuthEvent
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialOrd for AuthEvent
impl PartialOrd for AuthEvent
impl StructuralPartialEq for AuthEvent
Auto Trait Implementations§
impl Freeze for AuthEvent
impl RefUnwindSafe for AuthEvent
impl Send for AuthEvent
impl Sync for AuthEvent
impl Unpin for AuthEvent
impl UnsafeUnpin for AuthEvent
impl UnwindSafe for AuthEvent
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.