Struct aws_sdk_dlm::types::DeprecateRule
source · #[non_exhaustive]pub struct DeprecateRule {
pub count: Option<i32>,
pub interval: Option<i32>,
pub interval_unit: Option<RetentionIntervalUnitValues>,
}
Expand description
[Custom AMI policies only] Specifies an AMI deprecation rule for AMIs created by an AMI lifecycle policy.
For age-based schedules, you must specify Interval and IntervalUnit. For count-based schedules, you must specify Count.
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.count: Option<i32>
If the schedule has a count-based retention rule, this parameter specifies the number of oldest AMIs to deprecate. The count must be less than or equal to the schedule's retention count, and it can't be greater than 1000.
interval: Option<i32>
If the schedule has an age-based retention rule, this parameter specifies the period after which to deprecate AMIs created by the schedule. The period must be less than or equal to the schedule's retention period, and it can't be greater than 10 years. This is equivalent to 120 months, 520 weeks, or 3650 days.
interval_unit: Option<RetentionIntervalUnitValues>
The unit of time in which to measure the Interval.
Implementations§
source§impl DeprecateRule
impl DeprecateRule
sourcepub fn count(&self) -> Option<i32>
pub fn count(&self) -> Option<i32>
If the schedule has a count-based retention rule, this parameter specifies the number of oldest AMIs to deprecate. The count must be less than or equal to the schedule's retention count, and it can't be greater than 1000.
sourcepub fn interval(&self) -> Option<i32>
pub fn interval(&self) -> Option<i32>
If the schedule has an age-based retention rule, this parameter specifies the period after which to deprecate AMIs created by the schedule. The period must be less than or equal to the schedule's retention period, and it can't be greater than 10 years. This is equivalent to 120 months, 520 weeks, or 3650 days.
sourcepub fn interval_unit(&self) -> Option<&RetentionIntervalUnitValues>
pub fn interval_unit(&self) -> Option<&RetentionIntervalUnitValues>
The unit of time in which to measure the Interval.
source§impl DeprecateRule
impl DeprecateRule
sourcepub fn builder() -> DeprecateRuleBuilder
pub fn builder() -> DeprecateRuleBuilder
Creates a new builder-style object to manufacture DeprecateRule
.
Trait Implementations§
source§impl Clone for DeprecateRule
impl Clone for DeprecateRule
source§fn clone(&self) -> DeprecateRule
fn clone(&self) -> DeprecateRule
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for DeprecateRule
impl Debug for DeprecateRule
source§impl PartialEq for DeprecateRule
impl PartialEq for DeprecateRule
source§fn eq(&self, other: &DeprecateRule) -> bool
fn eq(&self, other: &DeprecateRule) -> bool
self
and other
values to be equal, and is used
by ==
.impl StructuralPartialEq for DeprecateRule
Auto Trait Implementations§
impl Freeze for DeprecateRule
impl RefUnwindSafe for DeprecateRule
impl Send for DeprecateRule
impl Sync for DeprecateRule
impl Unpin for DeprecateRule
impl UnwindSafe for DeprecateRule
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> 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