#[non_exhaustive]pub enum Answer {
Granted(Value),
Pending {
location: String,
retry_after: u64,
},
Denied {
status: u16,
reason: String,
},
}Available on crate feature
client only.Expand description
What a Person Server answered.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Granted(Value)
200: what was asked for, such as {"auth_token": …}.
Pending
202: a human is deciding. Poll location after retry_after seconds.
Fields
Denied
A refusal: a 4xx, or a 200 saying "permission": "denied".
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Answer
impl RefUnwindSafe for Answer
impl Send for Answer
impl Sync for Answer
impl Unpin for Answer
impl UnsafeUnpin for Answer
impl UnwindSafe for Answer
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