#[non_exhaustive]pub struct FileCacheDataRepositoryAssociation {
pub file_cache_path: Option<String>,
pub data_repository_path: Option<String>,
pub data_repository_subdirectories: Option<Vec<String>>,
pub nfs: Option<FileCacheNfsConfiguration>,
}
Expand description
The configuration for a data repository association (DRA) to be created during the Amazon File Cache resource creation. The DRA links the cache to either an Amazon S3 bucket or prefix, or a Network File System (NFS) data repository that supports the NFSv3 protocol.
The DRA does not support automatic import or automatic export.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. }
syntax; cannot be matched against without a wildcard ..
; and struct update syntax will not work.file_cache_path: Option<String>
A path on the cache that points to a high-level directory (such as /ns1/
) or subdirectory (such as /ns1/subdir/
) that will be mapped 1-1 with DataRepositoryPath
. The leading forward slash in the name is required. Two data repository associations cannot have overlapping cache paths. For example, if a data repository is associated with cache path /ns1/
, then you cannot link another data repository with cache path /ns1/ns2
.
This path specifies where in your cache files will be exported from. This cache directory can be linked to only one data repository, and no data repository other can be linked to the directory.
The cache path can only be set to root (/) on an NFS DRA when DataRepositorySubdirectories
is specified. If you specify root (/) as the cache path, you can create only one DRA on the cache.
The cache path cannot be set to root (/) for an S3 DRA.
data_repository_path: Option<String>
The path to the S3 or NFS data repository that links to the cache. You must provide one of the following paths:
-
The path can be an NFS data repository that links to the cache. The path can be in one of two formats:
-
If you are not using the
DataRepositorySubdirectories
parameter, the path is to an NFS Export directory (or one of its subdirectories) in the formatnfs://nfs-domain-name/exportpath
. You can therefore link a single NFS Export to a single data repository association. -
If you are using the
DataRepositorySubdirectories
parameter, the path is the domain name of the NFS file system in the formatnfs://filer-domain-name
, which indicates the root of the subdirectories specified with theDataRepositorySubdirectories
parameter.
-
-
The path can be an S3 bucket or prefix in the format
s3://bucket-name/prefix/
(whereprefix
is optional).
data_repository_subdirectories: Option<Vec<String>>
A list of NFS Exports that will be linked with this data repository association. The Export paths are in the format /exportpath1
. To use this parameter, you must configure DataRepositoryPath
as the domain name of the NFS file system. The NFS file system domain name in effect is the root of the subdirectories. Note that DataRepositorySubdirectories
is not supported for S3 data repositories.
nfs: Option<FileCacheNfsConfiguration>
The configuration for a data repository association that links an Amazon File Cache resource to an NFS data repository.
Implementations§
Source§impl FileCacheDataRepositoryAssociation
impl FileCacheDataRepositoryAssociation
Sourcepub fn file_cache_path(&self) -> Option<&str>
pub fn file_cache_path(&self) -> Option<&str>
A path on the cache that points to a high-level directory (such as /ns1/
) or subdirectory (such as /ns1/subdir/
) that will be mapped 1-1 with DataRepositoryPath
. The leading forward slash in the name is required. Two data repository associations cannot have overlapping cache paths. For example, if a data repository is associated with cache path /ns1/
, then you cannot link another data repository with cache path /ns1/ns2
.
This path specifies where in your cache files will be exported from. This cache directory can be linked to only one data repository, and no data repository other can be linked to the directory.
The cache path can only be set to root (/) on an NFS DRA when DataRepositorySubdirectories
is specified. If you specify root (/) as the cache path, you can create only one DRA on the cache.
The cache path cannot be set to root (/) for an S3 DRA.
Sourcepub fn data_repository_path(&self) -> Option<&str>
pub fn data_repository_path(&self) -> Option<&str>
The path to the S3 or NFS data repository that links to the cache. You must provide one of the following paths:
-
The path can be an NFS data repository that links to the cache. The path can be in one of two formats:
-
If you are not using the
DataRepositorySubdirectories
parameter, the path is to an NFS Export directory (or one of its subdirectories) in the formatnfs://nfs-domain-name/exportpath
. You can therefore link a single NFS Export to a single data repository association. -
If you are using the
DataRepositorySubdirectories
parameter, the path is the domain name of the NFS file system in the formatnfs://filer-domain-name
, which indicates the root of the subdirectories specified with theDataRepositorySubdirectories
parameter.
-
-
The path can be an S3 bucket or prefix in the format
s3://bucket-name/prefix/
(whereprefix
is optional).
Sourcepub fn data_repository_subdirectories(&self) -> &[String]
pub fn data_repository_subdirectories(&self) -> &[String]
A list of NFS Exports that will be linked with this data repository association. The Export paths are in the format /exportpath1
. To use this parameter, you must configure DataRepositoryPath
as the domain name of the NFS file system. The NFS file system domain name in effect is the root of the subdirectories. Note that DataRepositorySubdirectories
is not supported for S3 data repositories.
If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use .data_repository_subdirectories.is_none()
.
Sourcepub fn nfs(&self) -> Option<&FileCacheNfsConfiguration>
pub fn nfs(&self) -> Option<&FileCacheNfsConfiguration>
The configuration for a data repository association that links an Amazon File Cache resource to an NFS data repository.
Source§impl FileCacheDataRepositoryAssociation
impl FileCacheDataRepositoryAssociation
Sourcepub fn builder() -> FileCacheDataRepositoryAssociationBuilder
pub fn builder() -> FileCacheDataRepositoryAssociationBuilder
Creates a new builder-style object to manufacture FileCacheDataRepositoryAssociation
.
Trait Implementations§
Source§impl Clone for FileCacheDataRepositoryAssociation
impl Clone for FileCacheDataRepositoryAssociation
Source§fn clone(&self) -> FileCacheDataRepositoryAssociation
fn clone(&self) -> FileCacheDataRepositoryAssociation
1.0.0 · Source§const fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl PartialEq for FileCacheDataRepositoryAssociation
impl PartialEq for FileCacheDataRepositoryAssociation
Source§fn eq(&self, other: &FileCacheDataRepositoryAssociation) -> bool
fn eq(&self, other: &FileCacheDataRepositoryAssociation) -> bool
self
and other
values to be equal, and is used by ==
.impl StructuralPartialEq for FileCacheDataRepositoryAssociation
Auto Trait Implementations§
impl Freeze for FileCacheDataRepositoryAssociation
impl RefUnwindSafe for FileCacheDataRepositoryAssociation
impl Send for FileCacheDataRepositoryAssociation
impl Sync for FileCacheDataRepositoryAssociation
impl Unpin for FileCacheDataRepositoryAssociation
impl UnwindSafe for FileCacheDataRepositoryAssociation
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 moreSource§impl<T> Paint for Twhere
T: ?Sized,
impl<T> Paint for Twhere
T: ?Sized,
Source§fn fg(&self, value: Color) -> Painted<&T>
fn fg(&self, value: Color) -> Painted<&T>
Returns a styled value derived from self
with the foreground set to
value
.
This method should be used rarely. Instead, prefer to use color-specific
builder methods like red()
and
green()
, which have the same functionality but are
pithier.
§Example
Set foreground color to white using fg()
:
use yansi::{Paint, Color};
painted.fg(Color::White);
Set foreground color to white using white()
.
use yansi::Paint;
painted.white();
Source§fn bright_black(&self) -> Painted<&T>
fn bright_black(&self) -> Painted<&T>
Source§fn bright_red(&self) -> Painted<&T>
fn bright_red(&self) -> Painted<&T>
Source§fn bright_green(&self) -> Painted<&T>
fn bright_green(&self) -> Painted<&T>
Source§fn bright_yellow(&self) -> Painted<&T>
fn bright_yellow(&self) -> Painted<&T>
Source§fn bright_blue(&self) -> Painted<&T>
fn bright_blue(&self) -> Painted<&T>
Source§fn bright_magenta(&self) -> Painted<&T>
fn bright_magenta(&self) -> Painted<&T>
Source§fn bright_cyan(&self) -> Painted<&T>
fn bright_cyan(&self) -> Painted<&T>
Source§fn bright_white(&self) -> Painted<&T>
fn bright_white(&self) -> Painted<&T>
Source§fn bg(&self, value: Color) -> Painted<&T>
fn bg(&self, value: Color) -> Painted<&T>
Returns a styled value derived from self
with the background set to
value
.
This method should be used rarely. Instead, prefer to use color-specific
builder methods like on_red()
and
on_green()
, which have the same functionality but
are pithier.
§Example
Set background color to red using fg()
:
use yansi::{Paint, Color};
painted.bg(Color::Red);
Set background color to red using on_red()
.
use yansi::Paint;
painted.on_red();
Source§fn on_primary(&self) -> Painted<&T>
fn on_primary(&self) -> Painted<&T>
Source§fn on_magenta(&self) -> Painted<&T>
fn on_magenta(&self) -> Painted<&T>
Source§fn on_bright_black(&self) -> Painted<&T>
fn on_bright_black(&self) -> Painted<&T>
Source§fn on_bright_red(&self) -> Painted<&T>
fn on_bright_red(&self) -> Painted<&T>
Source§fn on_bright_green(&self) -> Painted<&T>
fn on_bright_green(&self) -> Painted<&T>
Source§fn on_bright_yellow(&self) -> Painted<&T>
fn on_bright_yellow(&self) -> Painted<&T>
Source§fn on_bright_blue(&self) -> Painted<&T>
fn on_bright_blue(&self) -> Painted<&T>
Source§fn on_bright_magenta(&self) -> Painted<&T>
fn on_bright_magenta(&self) -> Painted<&T>
Source§fn on_bright_cyan(&self) -> Painted<&T>
fn on_bright_cyan(&self) -> Painted<&T>
Source§fn on_bright_white(&self) -> Painted<&T>
fn on_bright_white(&self) -> Painted<&T>
Source§fn attr(&self, value: Attribute) -> Painted<&T>
fn attr(&self, value: Attribute) -> Painted<&T>
Enables the styling Attribute
value
.
This method should be used rarely. Instead, prefer to use
attribute-specific builder methods like bold()
and
underline()
, which have the same functionality
but are pithier.
§Example
Make text bold using attr()
:
use yansi::{Paint, Attribute};
painted.attr(Attribute::Bold);
Make text bold using using bold()
.
use yansi::Paint;
painted.bold();
Source§fn rapid_blink(&self) -> Painted<&T>
fn rapid_blink(&self) -> Painted<&T>
Source§fn quirk(&self, value: Quirk) -> Painted<&T>
fn quirk(&self, value: Quirk) -> Painted<&T>
Enables the yansi
Quirk
value
.
This method should be used rarely. Instead, prefer to use quirk-specific
builder methods like mask()
and
wrap()
, which have the same functionality but are
pithier.
§Example
Enable wrapping using .quirk()
:
use yansi::{Paint, Quirk};
painted.quirk(Quirk::Wrap);
Enable wrapping using wrap()
.
use yansi::Paint;
painted.wrap();
Source§fn clear(&self) -> Painted<&T>
👎Deprecated since 1.0.1: renamed to resetting()
due to conflicts with Vec::clear()
.
The clear()
method will be removed in a future release.
fn clear(&self) -> Painted<&T>
resetting()
due to conflicts with Vec::clear()
.
The clear()
method will be removed in a future release.Source§fn whenever(&self, value: Condition) -> Painted<&T>
fn whenever(&self, value: Condition) -> Painted<&T>
Conditionally enable styling based on whether the Condition
value
applies. Replaces any previous condition.
See the crate level docs for more details.
§Example
Enable styling painted
only when both stdout
and stderr
are TTYs:
use yansi::{Paint, Condition};
painted.red().on_yellow().whenever(Condition::STDOUTERR_ARE_TTY);