pub struct CasdoorResponse<EF: ExtraTokenFields> {
pub access_token: AccessToken,
pub token_type: BasicTokenType,
pub expires_in: Option<u64>,
pub refresh_token: Option<RefreshToken>,
pub scopes: Option<Vec<Scope>>,
pub extra_fields: EF,
}Fields§
§access_token: AccessToken§token_type: BasicTokenType§expires_in: Option<u64>§refresh_token: Option<RefreshToken>§scopes: Option<Vec<Scope>>§extra_fields: EFTrait Implementations§
Source§impl<EF: Clone + ExtraTokenFields> Clone for CasdoorResponse<EF>
impl<EF: Clone + ExtraTokenFields> Clone for CasdoorResponse<EF>
Source§fn clone(&self) -> CasdoorResponse<EF>
fn clone(&self) -> CasdoorResponse<EF>
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl<EF: Debug + ExtraTokenFields> Debug for CasdoorResponse<EF>
impl<EF: Debug + ExtraTokenFields> Debug for CasdoorResponse<EF>
Source§impl<'de, EF> Deserialize<'de> for CasdoorResponse<EF>where
EF: ExtraTokenFields,
impl<'de, EF> Deserialize<'de> for CasdoorResponse<EF>where
EF: ExtraTokenFields,
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>,
Source§impl<EF> Serialize for CasdoorResponse<EF>where
EF: ExtraTokenFields,
impl<EF> Serialize for CasdoorResponse<EF>where
EF: ExtraTokenFields,
Source§impl<EF> TokenResponse for CasdoorResponse<EF>where
EF: ExtraTokenFields,
impl<EF> TokenResponse for CasdoorResponse<EF>where
EF: ExtraTokenFields,
Source§fn access_token(&self) -> &AccessToken
fn access_token(&self) -> &AccessToken
REQUIRED. The access token issued by the authorization server.
Source§fn token_type(&self) -> &BasicTokenType
fn token_type(&self) -> &BasicTokenType
REQUIRED. The type of the token issued as described in
Section 7.1.
Value is case insensitive and deserialized to the generic TokenType parameter.
But in this particular case as the service is non compliant, it has a default value
Source§fn expires_in(&self) -> Option<Duration>
fn expires_in(&self) -> Option<Duration>
RECOMMENDED. The lifetime in seconds of the access token. For example, the value 3600 denotes that the access token will expire in one hour from the time the response was generated. If omitted, the authorization server SHOULD provide the expiration time via other means or document the default value.
Source§fn refresh_token(&self) -> Option<&RefreshToken>
fn refresh_token(&self) -> Option<&RefreshToken>
OPTIONAL. The refresh token, which can be used to obtain new access tokens using the same authorization grant as described in Section 6.
Source§fn scopes(&self) -> Option<&Vec<Scope>>
fn scopes(&self) -> Option<&Vec<Scope>>
OPTIONAL, if identical to the scope requested by the client; otherwise, REQUIRED. The
scope of the access token as described by
Section 3.3. If included in the response,
this space-delimited field is parsed into a Vec of individual scopes. If omitted from
the response, this field is None.