Struct azure_core::auth::TokenResponse
source · pub struct TokenResponse {
pub token: AccessToken,
pub expires_on: OffsetDateTime,
}
Expand description
Represents an Azure service bearer access token with expiry information.
Fields§
§token: AccessToken
Get the access token value.
expires_on: OffsetDateTime
Gets the time when the provided token expires.
Implementations§
source§impl TokenResponse
impl TokenResponse
sourcepub fn new(token: AccessToken, expires_on: OffsetDateTime) -> Self
pub fn new(token: AccessToken, expires_on: OffsetDateTime) -> Self
Create a new TokenResponse
.
Trait Implementations§
source§impl Clone for TokenResponse
impl Clone for TokenResponse
source§fn clone(&self) -> TokenResponse
fn clone(&self) -> TokenResponse
Returns a copy 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 moreAuto Trait Implementations§
impl RefUnwindSafe for TokenResponse
impl Send for TokenResponse
impl Sync for TokenResponse
impl Unpin for TokenResponse
impl UnwindSafe for TokenResponse
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