Struct aws_types::credentials::SharedCredentialsProvider
source · [−]pub struct SharedCredentialsProvider(_);
Expand description
Credentials Provider wrapper that may be shared
Newtype wrapper around ProvideCredentials that implements Clone using an internal Arc.
Implementations
sourcepub fn new(provider: impl ProvideCredentials + 'static) -> Self
pub fn new(provider: impl ProvideCredentials + 'static) -> Self
Create a new SharedCredentials provider from ProvideCredentials
The given provider will be wrapped in an internal Arc
. If your
provider is already in an Arc
, use SharedCredentialsProvider::from(provider)
instead.
Trait Implementations
sourcefn as_ref(&self) -> &(dyn ProvideCredentials + 'static)
fn as_ref(&self) -> &(dyn ProvideCredentials + 'static)
Converts this type into a shared reference of the (usually inferred) input type.
sourcefn clone(&self) -> SharedCredentialsProvider
fn clone(&self) -> SharedCredentialsProvider
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourcefn from(provider: Arc<dyn ProvideCredentials>) -> Self
fn from(provider: Arc<dyn ProvideCredentials>) -> Self
Converts to this type from the input type.
sourcefn provide_credentials<'a>(&'a self) -> ProvideCredentials<'a>ⓘNotable traits for ProvideCredentials<'_>impl Future for ProvideCredentials<'_> type Output = Result;
where
Self: 'a,
fn provide_credentials<'a>(&'a self) -> ProvideCredentials<'a>ⓘNotable traits for ProvideCredentials<'_>impl Future for ProvideCredentials<'_> type Output = Result;
where
Self: 'a,
Returns a future that provides credentials.
Auto Trait Implementations
Blanket Implementations
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more