/* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * * Licensed under the Apache License, Version 2.0 (the "License"). * You may not use this file except in compliance with the License. * A copy of the License is located at * * http://aws.amazon.com/apache2.0 * * or in the "license" file accompanying this file. This file is distributed * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either * express or implied. See the License for the specific language governing * permissions and limitations under the License. */ /* * Do not modify this file. This file is generated from the dlm-2018-01-12.normal.json service model. */ using System; using System.Collections.Generic; using System.Xml.Serialization; using System.Text; using System.IO; using System.Net; using Amazon.Runtime; using Amazon.Runtime.Internal; namespace Amazon.DLM.Model { /// /// [Snapshot and AMI policies only] Specifies a schedule for a snapshot or AMI /// lifecycle policy. /// public partial class Schedule { private ArchiveRule _archiveRule; private bool? _copyTags; private CreateRule _createRule; private List _crossRegionCopyRules = new List(); private DeprecateRule _deprecateRule; private FastRestoreRule _fastRestoreRule; private string _name; private RetainRule _retainRule; private List _shareRules = new List(); private List _tagsToAdd = new List(); private List _variableTags = new List(); /// /// Gets and sets the property ArchiveRule. /// /// [Snapshot policies that target volumes only] The snapshot archiving rule for /// the schedule. When you specify an archiving rule, snapshots are automatically moved /// from the standard tier to the archive tier once the schedule's retention threshold /// is met. Snapshots are then retained in the archive tier for the archive retention /// period that you specify. /// /// /// /// For more information about using snapshot archiving, see Considerations /// for snapshot lifecycle policies. /// /// public ArchiveRule ArchiveRule { get { return this._archiveRule; } set { this._archiveRule = value; } } // Check to see if ArchiveRule property is set internal bool IsSetArchiveRule() { return this._archiveRule != null; } /// /// Gets and sets the property CopyTags. /// /// Copy all user-defined tags on a source volume to snapshots of the volume created by /// this policy. /// /// public bool CopyTags { get { return this._copyTags.GetValueOrDefault(); } set { this._copyTags = value; } } // Check to see if CopyTags property is set internal bool IsSetCopyTags() { return this._copyTags.HasValue; } /// /// Gets and sets the property CreateRule. /// /// The creation rule. /// /// public CreateRule CreateRule { get { return this._createRule; } set { this._createRule = value; } } // Check to see if CreateRule property is set internal bool IsSetCreateRule() { return this._createRule != null; } /// /// Gets and sets the property CrossRegionCopyRules. /// /// Specifies a rule for copying snapshots or AMIs across regions. /// /// /// /// You can't specify cross-Region copy rules for policies that create snapshots on an /// Outpost. If the policy creates snapshots in a Region, then snapshots can be copied /// to up to three Regions or Outposts. /// /// /// [AWSProperty(Min=0, Max=3)] public List CrossRegionCopyRules { get { return this._crossRegionCopyRules; } set { this._crossRegionCopyRules = value; } } // Check to see if CrossRegionCopyRules property is set internal bool IsSetCrossRegionCopyRules() { return this._crossRegionCopyRules != null && this._crossRegionCopyRules.Count > 0; } /// /// Gets and sets the property DeprecateRule. /// /// [AMI policies only] The AMI deprecation rule for the schedule. /// /// public DeprecateRule DeprecateRule { get { return this._deprecateRule; } set { this._deprecateRule = value; } } // Check to see if DeprecateRule property is set internal bool IsSetDeprecateRule() { return this._deprecateRule != null; } /// /// Gets and sets the property FastRestoreRule. /// /// [Snapshot policies only] The rule for enabling fast snapshot restore. /// /// public FastRestoreRule FastRestoreRule { get { return this._fastRestoreRule; } set { this._fastRestoreRule = value; } } // Check to see if FastRestoreRule property is set internal bool IsSetFastRestoreRule() { return this._fastRestoreRule != null; } /// /// Gets and sets the property Name. /// /// The name of the schedule. /// /// [AWSProperty(Min=0, Max=120)] public string Name { get { return this._name; } set { this._name = value; } } // Check to see if Name property is set internal bool IsSetName() { return this._name != null; } /// /// Gets and sets the property RetainRule. /// /// The retention rule for snapshots or AMIs created by the policy. /// /// public RetainRule RetainRule { get { return this._retainRule; } set { this._retainRule = value; } } // Check to see if RetainRule property is set internal bool IsSetRetainRule() { return this._retainRule != null; } /// /// Gets and sets the property ShareRules. /// /// [Snapshot policies only] The rule for sharing snapshots with other Amazon /// Web Services accounts. /// /// [AWSProperty(Min=0, Max=1)] public List ShareRules { get { return this._shareRules; } set { this._shareRules = value; } } // Check to see if ShareRules property is set internal bool IsSetShareRules() { return this._shareRules != null && this._shareRules.Count > 0; } /// /// Gets and sets the property TagsToAdd. /// /// The tags to apply to policy-created resources. These user-defined tags are in addition /// to the Amazon Web Services-added lifecycle tags. /// /// [AWSProperty(Min=0, Max=45)] public List TagsToAdd { get { return this._tagsToAdd; } set { this._tagsToAdd = value; } } // Check to see if TagsToAdd property is set internal bool IsSetTagsToAdd() { return this._tagsToAdd != null && this._tagsToAdd.Count > 0; } /// /// Gets and sets the property VariableTags. /// /// [AMI policies and snapshot policies that target instances only] 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. /// /// [AWSProperty(Min=0, Max=45)] public List VariableTags { get { return this._variableTags; } set { this._variableTags = value; } } // Check to see if VariableTags property is set internal bool IsSetVariableTags() { return this._variableTags != null && this._variableTags.Count > 0; } } }