/*
* 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 shield-2016-06-02.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.Shield.Model
{
///
/// A grouping of protected resources that you and Shield Advanced can monitor as a collective.
/// This resource grouping improves the accuracy of detection and reduces false positives.
///
public partial class ProtectionGroup
{
private ProtectionGroupAggregation _aggregation;
private List _members = new List();
private ProtectionGroupPattern _pattern;
private string _protectionGroupArn;
private string _protectionGroupId;
private ProtectedResourceType _resourceType;
///
/// Gets and sets the property Aggregation.
///
/// Defines how Shield combines resource data for the group in order to detect, mitigate,
/// and report events.
///
/// -
///
/// Sum - Use the total traffic across the group. This is a good choice for most cases.
/// Examples include Elastic IP addresses for EC2 instances that scale manually or automatically.
///
///
-
///
/// Mean - Use the average of the traffic across the group. This is a good choice for
/// resources that share traffic uniformly. Examples include accelerators and load balancers.
///
///
-
///
/// Max - Use the highest traffic from each resource. This is useful for resources that
/// don't share traffic and for resources that share that traffic in a non-uniform way.
/// Examples include Amazon CloudFront distributions and origin resources for CloudFront
/// distributions.
///
///
///
[AWSProperty(Required=true)]
public ProtectionGroupAggregation Aggregation
{
get { return this._aggregation; }
set { this._aggregation = value; }
}
// Check to see if Aggregation property is set
internal bool IsSetAggregation()
{
return this._aggregation != null;
}
///
/// Gets and sets the property Members.
///
/// The ARNs (Amazon Resource Names) of the resources to include in the protection group.
/// You must set this when you set Pattern
to ARBITRARY
and
/// you must not set it for any other Pattern
setting.
///
///
[AWSProperty(Required=true, Min=0, Max=10000)]
public List Members
{
get { return this._members; }
set { this._members = value; }
}
// Check to see if Members property is set
internal bool IsSetMembers()
{
return this._members != null && this._members.Count > 0;
}
///
/// Gets and sets the property Pattern.
///
/// The criteria to use to choose the protected resources for inclusion in the group.
/// You can include all resources that have protections, provide a list of resource ARNs
/// (Amazon Resource Names), or include all resources of a specified resource type.
///
///
[AWSProperty(Required=true)]
public ProtectionGroupPattern Pattern
{
get { return this._pattern; }
set { this._pattern = value; }
}
// Check to see if Pattern property is set
internal bool IsSetPattern()
{
return this._pattern != null;
}
///
/// Gets and sets the property ProtectionGroupArn.
///
/// The ARN (Amazon Resource Name) of the protection group.
///
///
[AWSProperty(Min=1, Max=2048)]
public string ProtectionGroupArn
{
get { return this._protectionGroupArn; }
set { this._protectionGroupArn = value; }
}
// Check to see if ProtectionGroupArn property is set
internal bool IsSetProtectionGroupArn()
{
return this._protectionGroupArn != null;
}
///
/// Gets and sets the property ProtectionGroupId.
///
/// The name of the protection group. You use this to identify the protection group in
/// lists and to manage the protection group, for example to update, delete, or describe
/// it.
///
///
[AWSProperty(Required=true, Min=1, Max=36)]
public string ProtectionGroupId
{
get { return this._protectionGroupId; }
set { this._protectionGroupId = value; }
}
// Check to see if ProtectionGroupId property is set
internal bool IsSetProtectionGroupId()
{
return this._protectionGroupId != null;
}
///
/// Gets and sets the property ResourceType.
///
/// The resource type to include in the protection group. All protected resources of this
/// type are included in the protection group. You must set this when you set Pattern
/// to BY_RESOURCE_TYPE
and you must not set it for any other Pattern
/// setting.
///
///
public ProtectedResourceType ResourceType
{
get { return this._resourceType; }
set { this._resourceType = value; }
}
// Check to see if ResourceType property is set
internal bool IsSetResourceType()
{
return this._resourceType != null;
}
}
}