pub struct Builder { /* private fields */ }Expand description
Builder for EnvConfigFiles.
Implementations§
Source§impl Builder
impl Builder
Sourcepub fn include_default_config_file(
self,
include_default_config_file: bool,
) -> Self
pub fn include_default_config_file( self, include_default_config_file: bool, ) -> Self
Include the default SDK config file in the list of profile files to be loaded.
The default SDK config typically resides in ~/.aws/config. When this flag is enabled,
this config file will be included in the profile files that get loaded in the built
EnvConfigFiles file set.
This flag defaults to false when using the builder to construct EnvConfigFiles.
Sourcepub fn include_default_credentials_file(
self,
include_default_credentials_file: bool,
) -> Self
pub fn include_default_credentials_file( self, include_default_credentials_file: bool, ) -> Self
Include the default SDK credentials file in the list of profile files to be loaded.
The default SDK credentials typically reside in ~/.aws/credentials. When this flag is enabled,
this credentials file will be included in the profile files that get loaded in the built
EnvConfigFiles file set.
This flag defaults to false when using the builder to construct EnvConfigFiles.
Sourcepub fn with_file(
self,
kind: EnvConfigFileKind,
file: impl Into<PathBuf>,
) -> Self
pub fn with_file( self, kind: EnvConfigFileKind, file: impl Into<PathBuf>, ) -> Self
Include a custom file in the list of profile files to be loaded.
The kind informs the parser how to treat the file. If it’s intended to be like
the SDK credentials file typically in ~/.aws/config, then use EnvConfigFileKind::Config.
Otherwise, use EnvConfigFileKind::Credentials.
Sourcepub fn with_contents(
self,
kind: EnvConfigFileKind,
contents: impl Into<String>,
) -> Self
pub fn with_contents( self, kind: EnvConfigFileKind, contents: impl Into<String>, ) -> Self
Include custom file contents in the list of profile files to be loaded.
The kind informs the parser how to treat the file. If it’s intended to be like
the SDK credentials file typically in ~/.aws/config, then use EnvConfigFileKind::Config.
Otherwise, use EnvConfigFileKind::Credentials.
Sourcepub fn build(self) -> EnvConfigFiles
pub fn build(self) -> EnvConfigFiles
Build the EnvConfigFiles file set.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Builder
impl RefUnwindSafe for Builder
impl Send for Builder
impl Sync for Builder
impl Unpin for Builder
impl UnwindSafe for Builder
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more