public static final class CfnLifecyclePolicy.ScheduleProperty.Builder
extends java.lang.Object
CfnLifecyclePolicy.ScheduleProperty
Constructor and Description |
---|
Builder() |
public CfnLifecyclePolicy.ScheduleProperty.Builder copyTags(java.lang.Boolean copyTags)
CfnLifecyclePolicy.ScheduleProperty.getCopyTags()
copyTags
- Copy all user-defined tags on a source volume to snapshots of the volume created by this policy.this
public CfnLifecyclePolicy.ScheduleProperty.Builder copyTags(IResolvable copyTags)
CfnLifecyclePolicy.ScheduleProperty.getCopyTags()
copyTags
- Copy all user-defined tags on a source volume to snapshots of the volume created by this policy.this
public CfnLifecyclePolicy.ScheduleProperty.Builder createRule(IResolvable createRule)
CfnLifecyclePolicy.ScheduleProperty.getCreateRule()
createRule
- The creation rule.this
public CfnLifecyclePolicy.ScheduleProperty.Builder createRule(CfnLifecyclePolicy.CreateRuleProperty createRule)
CfnLifecyclePolicy.ScheduleProperty.getCreateRule()
createRule
- The creation rule.this
public CfnLifecyclePolicy.ScheduleProperty.Builder crossRegionCopyRules(IResolvable crossRegionCopyRules)
CfnLifecyclePolicy.ScheduleProperty.getCrossRegionCopyRules()
crossRegionCopyRules
- The rule for cross-Region snapshot copies.
You can only specify cross-Region copy rules for policies that create snapshots in a Region. If the policy creates snapshots on an Outpost, then you cannot copy the snapshots to a Region or to an Outpost. If the policy creates snapshots in a Region, then snapshots can be copied to up to three Regions or Outposts.this
public CfnLifecyclePolicy.ScheduleProperty.Builder crossRegionCopyRules(java.util.List<? extends java.lang.Object> crossRegionCopyRules)
CfnLifecyclePolicy.ScheduleProperty.getCrossRegionCopyRules()
crossRegionCopyRules
- The rule for cross-Region snapshot copies.
You can only specify cross-Region copy rules for policies that create snapshots in a Region. If the policy creates snapshots on an Outpost, then you cannot copy the snapshots to a Region or to an Outpost. If the policy creates snapshots in a Region, then snapshots can be copied to up to three Regions or Outposts.this
public CfnLifecyclePolicy.ScheduleProperty.Builder deprecateRule(IResolvable deprecateRule)
CfnLifecyclePolicy.ScheduleProperty.getDeprecateRule()
deprecateRule
- The AMI deprecation rule for the schedule.this
public CfnLifecyclePolicy.ScheduleProperty.Builder deprecateRule(CfnLifecyclePolicy.DeprecateRuleProperty deprecateRule)
CfnLifecyclePolicy.ScheduleProperty.getDeprecateRule()
deprecateRule
- The AMI deprecation rule for the schedule.this
public CfnLifecyclePolicy.ScheduleProperty.Builder fastRestoreRule(IResolvable fastRestoreRule)
CfnLifecyclePolicy.ScheduleProperty.getFastRestoreRule()
fastRestoreRule
- The rule for enabling fast snapshot restore.this
public CfnLifecyclePolicy.ScheduleProperty.Builder fastRestoreRule(CfnLifecyclePolicy.FastRestoreRuleProperty fastRestoreRule)
CfnLifecyclePolicy.ScheduleProperty.getFastRestoreRule()
fastRestoreRule
- The rule for enabling fast snapshot restore.this
public CfnLifecyclePolicy.ScheduleProperty.Builder name(java.lang.String name)
CfnLifecyclePolicy.ScheduleProperty.getName()
name
- The name of the schedule.this
public CfnLifecyclePolicy.ScheduleProperty.Builder retainRule(IResolvable retainRule)
CfnLifecyclePolicy.ScheduleProperty.getRetainRule()
retainRule
- The retention rule.this
public CfnLifecyclePolicy.ScheduleProperty.Builder retainRule(CfnLifecyclePolicy.RetainRuleProperty retainRule)
CfnLifecyclePolicy.ScheduleProperty.getRetainRule()
retainRule
- The retention rule.this
public CfnLifecyclePolicy.ScheduleProperty.Builder shareRules(IResolvable shareRules)
CfnLifecyclePolicy.ScheduleProperty.getShareRules()
shareRules
- The rule for sharing snapshots with other AWS accounts .this
public CfnLifecyclePolicy.ScheduleProperty.Builder shareRules(java.util.List<? extends java.lang.Object> shareRules)
CfnLifecyclePolicy.ScheduleProperty.getShareRules()
shareRules
- The rule for sharing snapshots with other AWS accounts .this
public CfnLifecyclePolicy.ScheduleProperty.Builder tagsToAdd(IResolvable tagsToAdd)
CfnLifecyclePolicy.ScheduleProperty.getTagsToAdd()
tagsToAdd
- The tags to apply to policy-created resources.
These user-defined tags are in addition to the AWS -added lifecycle tags.this
public CfnLifecyclePolicy.ScheduleProperty.Builder tagsToAdd(java.util.List<? extends java.lang.Object> tagsToAdd)
CfnLifecyclePolicy.ScheduleProperty.getTagsToAdd()
tagsToAdd
- The tags to apply to policy-created resources.
These user-defined tags are in addition to the AWS -added lifecycle tags.this
public CfnLifecyclePolicy.ScheduleProperty.Builder variableTags(IResolvable variableTags)
CfnLifecyclePolicy.ScheduleProperty.getVariableTags()
variableTags
- A collection of key/value pairs with values determined dynamically when the policy is executed.
Keys may be any valid Amazon EC2 tag key. Values must be in one of the two following formats: $(instance-id)
or $(timestamp)
. Variable tags are only valid for EBS Snapshot Management – Instance policies.this
public CfnLifecyclePolicy.ScheduleProperty.Builder variableTags(java.util.List<? extends java.lang.Object> variableTags)
CfnLifecyclePolicy.ScheduleProperty.getVariableTags()
variableTags
- A collection of key/value pairs with values determined dynamically when the policy is executed.
Keys may be any valid Amazon EC2 tag key. Values must be in one of the two following formats: $(instance-id)
or $(timestamp)
. Variable tags are only valid for EBS Snapshot Management – Instance policies.this
public CfnLifecyclePolicy.ScheduleProperty build()
CfnLifecyclePolicy.ScheduleProperty
java.lang.NullPointerException
- if any required attribute was not provided