pub struct OAuth2Flows {
pub authorization_code: Option<OAuth2Flow>,
pub client_credentials: Option<OAuth2Flow>,
pub implicit: Option<OAuth2ImplicitFlow>,
pub password: Option<OAuth2Flow>,
}Expand description
OAuth2 flow configurations.
Represents the different OAuth2 flows supported by OpenAPI.
Fields§
Authorization Code flow
client_credentials: Option<OAuth2Flow>Client Credentials flow
implicit: Option<OAuth2ImplicitFlow>Implicit flow (deprecated in OAuth 2.1)
password: Option<OAuth2Flow>Password flow (deprecated in OAuth 2.1)
Implementations§
Source§impl OAuth2Flows
impl OAuth2Flows
Creates a new OAuth2Flows with authorization code flow.
Sourcepub fn client_credentials(
token_url: impl Into<String>,
scopes: impl IntoIterator<Item = (impl Into<String>, impl Into<String>)>,
) -> Self
pub fn client_credentials( token_url: impl Into<String>, scopes: impl IntoIterator<Item = (impl Into<String>, impl Into<String>)>, ) -> Self
Creates a new OAuth2Flows with client credentials flow.
Trait Implementations§
Source§impl Clone for OAuth2Flows
impl Clone for OAuth2Flows
Source§fn clone(&self) -> OAuth2Flows
fn clone(&self) -> OAuth2Flows
Returns a duplicate of the value. Read more
1.0.0 · 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 OAuth2Flows
impl Debug for OAuth2Flows
Source§impl Default for OAuth2Flows
impl Default for OAuth2Flows
Source§fn default() -> OAuth2Flows
fn default() -> OAuth2Flows
Returns the “default value” for a type. Read more
Source§impl PartialEq for OAuth2Flows
impl PartialEq for OAuth2Flows
impl StructuralPartialEq for OAuth2Flows
Auto Trait Implementations§
impl Freeze for OAuth2Flows
impl RefUnwindSafe for OAuth2Flows
impl Send for OAuth2Flows
impl Sync for OAuth2Flows
impl Unpin for OAuth2Flows
impl UnwindSafe for OAuth2Flows
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