pub enum DeviceGrantState {
Pending,
Approved {
subject: String,
},
Denied,
}Expand description
Where a device grant stands in its lifecycle. Expiry is not a stored state: it is derived from
DeviceGrant::expires_at against the clock, so a grant cannot be “un-expired” by a state
write and an expired-but-unpolled grant needs no sweeper to be correct (hosts may still sweep
storage for hygiene).
Variants§
Pending
Waiting for the user to act at the verification URI.
Approved
The user approved; the next well-paced poll redeems the grant (single use).
Denied
The user declined; the next poll returns access_denied.
Trait Implementations§
Source§impl Clone for DeviceGrantState
impl Clone for DeviceGrantState
Source§fn clone(&self) -> DeviceGrantState
fn clone(&self) -> DeviceGrantState
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 DeviceGrantState
impl Debug for DeviceGrantState
Source§impl<'de> Deserialize<'de> for DeviceGrantState
impl<'de> Deserialize<'de> for DeviceGrantState
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
impl Eq for DeviceGrantState
Source§impl PartialEq for DeviceGrantState
impl PartialEq for DeviceGrantState
Source§impl Serialize for DeviceGrantState
impl Serialize for DeviceGrantState
impl StructuralPartialEq for DeviceGrantState
Auto Trait Implementations§
impl Freeze for DeviceGrantState
impl RefUnwindSafe for DeviceGrantState
impl Send for DeviceGrantState
impl Sync for DeviceGrantState
impl Unpin for DeviceGrantState
impl UnsafeUnpin for DeviceGrantState
impl UnwindSafe for DeviceGrantState
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