Struct rusoto_credential::AutoRefreshingProvider [−][src]
Wrapper for ProvideAwsCredentials
that caches the credentials returned by the
wrapped provider. Each time the credentials are accessed, they are checked to see if
they have expired, in which case they are retrieved from the wrapped provider again.
In order to access the wrapped provider, for instance to set a timeout, the get_ref
and get_mut
methods can be used.
Implementations
impl<P: ProvideAwsCredentials + 'static> AutoRefreshingProvider<P>
[src]
pub fn new(provider: P) -> Result<AutoRefreshingProvider<P>, CredentialsError>
[src]
Create a new AutoRefreshingProvider
around the provided base provider.
pub fn get_ref(&self) -> &P
[src]
Get a shared reference to the wrapped provider.
pub fn get_mut(&mut self) -> &mut P
[src]
Get a mutable reference to the wrapped provider.
This can be used to call set_timeout
on the wrapped
provider.
Trait Implementations
impl<P: Clone + ProvideAwsCredentials + 'static> Clone for AutoRefreshingProvider<P>
[src]
fn clone(&self) -> AutoRefreshingProvider<P>
[src]
pub fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl<P: Debug + ProvideAwsCredentials + 'static> Debug for AutoRefreshingProvider<P>
[src]
impl<P: ProvideAwsCredentials + Send + Sync + 'static> ProvideAwsCredentials for AutoRefreshingProvider<P>
[src]
fn credentials<'life0, 'async_trait>(
&'life0 self
) -> Pin<Box<dyn Future<Output = Result<AwsCredentials, CredentialsError>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
[src]
&'life0 self
) -> Pin<Box<dyn Future<Output = Result<AwsCredentials, CredentialsError>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
Auto Trait Implementations
impl<P> !RefUnwindSafe for AutoRefreshingProvider<P>
impl<P> Send for AutoRefreshingProvider<P> where
P: Send,
P: Send,
impl<P> Sync for AutoRefreshingProvider<P> where
P: Sync,
P: Sync,
impl<P> Unpin for AutoRefreshingProvider<P> where
P: Unpin,
P: Unpin,
impl<P> !UnwindSafe for AutoRefreshingProvider<P>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T> Instrument for T
[src]
pub fn instrument(self, span: Span) -> Instrumented<Self>
[src]
pub fn in_current_span(self) -> Instrumented<Self>
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,