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§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)