/*
* 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 cross-Region copy rule for snapshot
/// and AMI policies.
///
///
///
/// To specify a cross-Region copy action for event-based polices, use CrossRegionCopyAction.
///
///
///
public partial class CrossRegionCopyRule
{
private string _cmkArn;
private bool? _copyTags;
private CrossRegionCopyDeprecateRule _deprecateRule;
private bool? _encrypted;
private CrossRegionCopyRetainRule _retainRule;
private string _target;
private string _targetRegion;
///
/// Gets and sets the property CmkArn.
///
/// The Amazon Resource Name (ARN) of the KMS key to use for EBS encryption. If this parameter
/// is not specified, the default KMS key for the account is used.
///
///
[AWSProperty(Min=0, Max=2048)]
public string CmkArn
{
get { return this._cmkArn; }
set { this._cmkArn = value; }
}
// Check to see if CmkArn property is set
internal bool IsSetCmkArn()
{
return this._cmkArn != null;
}
///
/// Gets and sets the property CopyTags.
///
/// Indicates whether to copy all user-defined tags from the source snapshot or AMI to
/// the cross-Region copy.
///
///
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 DeprecateRule.
///
/// [AMI policies only] The AMI deprecation rule for cross-Region AMI copies created
/// by the rule.
///
///
public CrossRegionCopyDeprecateRule 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 Encrypted.
///
/// To encrypt a copy of an unencrypted snapshot if encryption by default is not enabled,
/// enable encryption using this parameter. Copies of encrypted snapshots are encrypted,
/// even if this parameter is false or if encryption by default is not enabled.
///
///
[AWSProperty(Required=true)]
public bool Encrypted
{
get { return this._encrypted.GetValueOrDefault(); }
set { this._encrypted = value; }
}
// Check to see if Encrypted property is set
internal bool IsSetEncrypted()
{
return this._encrypted.HasValue;
}
///
/// Gets and sets the property RetainRule.
///
/// The retention rule that indicates how long the cross-Region snapshot or AMI copies
/// are to be retained in the destination Region.
///
///
public CrossRegionCopyRetainRule 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 Target.
///
/// The target Region or the Amazon Resource Name (ARN) of the target Outpost for the
/// snapshot copies.
///
///
///
/// Use this parameter instead of TargetRegion. Do not specify both.
///
///
[AWSProperty(Min=0, Max=2048)]
public string Target
{
get { return this._target; }
set { this._target = value; }
}
// Check to see if Target property is set
internal bool IsSetTarget()
{
return this._target != null;
}
///
/// Gets and sets the property TargetRegion.
///
/// Avoid using this parameter when creating new policies. Instead, use Target
/// to specify a target Region or a target Outpost for snapshot copies.
///
///
///
/// For policies created before the Target parameter was introduced, this parameter
/// indicates the target Region for snapshot copies.
///
///
///
[AWSProperty(Min=0, Max=16)]
public string TargetRegion
{
get { return this._targetRegion; }
set { this._targetRegion = value; }
}
// Check to see if TargetRegion property is set
internal bool IsSetTargetRegion()
{
return this._targetRegion != null;
}
}
}