pub enum Flow {
DeviceAuthorization(DeviceAuthorization),
Implicit(Implicit),
Password(Password),
ClientCredentials(ClientCredentials),
AuthorizationCode(AuthorizationCode),
}Expand description
OAuth2 flow configuration object.
See more details at https://spec.openapis.org/oas/latest.html#oauth-flows-object.
Variants§
DeviceAuthorization(DeviceAuthorization)
Define device authorization Flow type. See DeviceAuthorization::new for usage
details. Added in OpenAPI 3.2.
Declared first because this enum is untagged: the other variants ignore the unknown
deviceAuthorizationUrl key, so a device flow reached through a bare Flow
deserialization would otherwise be misparsed as Flow::Password. Inside an
OAuth2 document the flow name decides the variant — see [deserialize_flows].
Implicit(Implicit)
Define implicit Flow type. See Implicit::new for usage details.
Soon to be deprecated by https://datatracker.ietf.org/doc/html/draft-ietf-oauth-security-topics.
Password(Password)
Define password Flow type. See Password::new for usage details.
ClientCredentials(ClientCredentials)
Define client credentials Flow type. See ClientCredentials::new for usage details.
AuthorizationCode(AuthorizationCode)
Define authorization code Flow type. See AuthorizationCode::new for usage details.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Flow
impl<'de> Deserialize<'de> for Flow
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>,
impl Eq for Flow
impl StructuralPartialEq for Flow
Auto Trait Implementations§
impl Freeze for Flow
impl RefUnwindSafe for Flow
impl Send for Flow
impl Sync for Flow
impl Unpin for Flow
impl UnsafeUnpin for Flow
impl UnwindSafe for Flow
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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
key and return true if they are equal.