/*
* 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 ec2-2016-11-15.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.EC2.Model
{
///
/// Container for the parameters to the ModifyNetworkInterfaceAttribute operation.
/// Modifies the specified network interface attribute. You can specify only one attribute
/// at a time. You can use this action to attach and detach security groups from an existing
/// EC2 instance.
///
public partial class ModifyNetworkInterfaceAttributeRequest : AmazonEC2Request
{
private NetworkInterfaceAttachmentChanges _attachment;
private string _description;
private EnaSrdSpecification _enaSrdSpecification;
private List _groups = new List();
private string _networkInterfaceId;
private bool? _sourceDestCheck;
///
/// Gets and sets the property Attachment.
///
/// Information about the interface attachment. If modifying the delete on termination
/// attribute, you must specify the ID of the interface attachment.
///
///
public NetworkInterfaceAttachmentChanges Attachment
{
get { return this._attachment; }
set { this._attachment = value; }
}
// Check to see if Attachment property is set
internal bool IsSetAttachment()
{
return this._attachment != null;
}
///
/// Gets and sets the property Description.
///
/// A description for the network interface.
///
///
public string Description
{
get { return this._description; }
set { this._description = value; }
}
// Check to see if Description property is set
internal bool IsSetDescription()
{
return this._description != null;
}
///
/// Gets and sets the property EnaSrdSpecification.
///
/// Updates the ENA Express configuration for the network interface that’s attached to
/// the instance.
///
///
public EnaSrdSpecification EnaSrdSpecification
{
get { return this._enaSrdSpecification; }
set { this._enaSrdSpecification = value; }
}
// Check to see if EnaSrdSpecification property is set
internal bool IsSetEnaSrdSpecification()
{
return this._enaSrdSpecification != null;
}
///
/// Gets and sets the property Groups.
///
/// Changes the security groups for the network interface. The new set of groups you specify
/// replaces the current set. You must specify at least one group, even if it's just the
/// default security group in the VPC. You must specify the ID of the security group,
/// not the name.
///
///
public List Groups
{
get { return this._groups; }
set { this._groups = value; }
}
// Check to see if Groups property is set
internal bool IsSetGroups()
{
return this._groups != null && this._groups.Count > 0;
}
///
/// Gets and sets the property NetworkInterfaceId.
///
/// The ID of the network interface.
///
///
[AWSProperty(Required=true)]
public string NetworkInterfaceId
{
get { return this._networkInterfaceId; }
set { this._networkInterfaceId = value; }
}
// Check to see if NetworkInterfaceId property is set
internal bool IsSetNetworkInterfaceId()
{
return this._networkInterfaceId != null;
}
///
/// Gets and sets the property SourceDestCheck.
///
/// Enable or disable source/destination checks, which ensure that the instance is either
/// the source or the destination of any traffic that it receives. If the value is true
,
/// source/destination checks are enabled; otherwise, they are disabled. The default value
/// is true
. You must disable source/destination checks if the instance runs
/// services such as network address translation, routing, or firewalls.
///
///
public bool SourceDestCheck
{
get { return this._sourceDestCheck.GetValueOrDefault(); }
set { this._sourceDestCheck = value; }
}
// Check to see if SourceDestCheck property is set
internal bool IsSetSourceDestCheck()
{
return this._sourceDestCheck.HasValue;
}
}
}