/* * 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 CreateTrafficMirrorSession operation. /// Creates a Traffic Mirror session. /// /// /// /// A Traffic Mirror session actively copies packets from a Traffic Mirror source to a /// Traffic Mirror target. Create a filter, and then assign it to the session to define /// a subset of the traffic to mirror, for example all TCP traffic. /// /// /// /// The Traffic Mirror source and the Traffic Mirror target (monitoring appliances) can /// be in the same VPC, or in a different VPC connected via VPC peering or a transit gateway. /// /// /// /// /// By default, no traffic is mirrored. Use CreateTrafficMirrorFilter /// to create filter rules that specify the traffic to mirror. /// /// public partial class CreateTrafficMirrorSessionRequest : AmazonEC2Request { private string _clientToken; private string _description; private string _networkInterfaceId; private int? _packetLength; private int? _sessionNumber; private List _tagSpecifications = new List(); private string _trafficMirrorFilterId; private string _trafficMirrorTargetId; private int? _virtualNetworkId; /// /// Gets and sets the property ClientToken. /// /// Unique, case-sensitive identifier that you provide to ensure the idempotency of the /// request. For more information, see How /// to ensure idempotency. /// /// public string ClientToken { get { return this._clientToken; } set { this._clientToken = value; } } // Check to see if ClientToken property is set internal bool IsSetClientToken() { return this._clientToken != null; } /// /// Gets and sets the property Description. /// /// The description of the Traffic Mirror session. /// /// 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 NetworkInterfaceId. /// /// The ID of the source 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 PacketLength. /// /// The number of bytes in each packet to mirror. These are bytes after the VXLAN header. /// Do not specify this parameter when you want to mirror the entire packet. To mirror /// a subset of the packet, set this to the length (in bytes) that you want to mirror. /// For example, if you set this value to 100, then the first 100 bytes that meet the /// filter criteria are copied to the target. /// /// /// /// If you do not want to mirror the entire packet, use the PacketLength /// parameter to specify the number of bytes in each packet to mirror. /// /// public int PacketLength { get { return this._packetLength.GetValueOrDefault(); } set { this._packetLength = value; } } // Check to see if PacketLength property is set internal bool IsSetPacketLength() { return this._packetLength.HasValue; } /// /// Gets and sets the property SessionNumber. /// /// The session number determines the order in which sessions are evaluated when an interface /// is used by multiple sessions. The first session with a matching filter is the one /// that mirrors the packets. /// /// /// /// Valid values are 1-32766. /// /// [AWSProperty(Required=true)] public int SessionNumber { get { return this._sessionNumber.GetValueOrDefault(); } set { this._sessionNumber = value; } } // Check to see if SessionNumber property is set internal bool IsSetSessionNumber() { return this._sessionNumber.HasValue; } /// /// Gets and sets the property TagSpecifications. /// /// The tags to assign to a Traffic Mirror session. /// /// public List TagSpecifications { get { return this._tagSpecifications; } set { this._tagSpecifications = value; } } // Check to see if TagSpecifications property is set internal bool IsSetTagSpecifications() { return this._tagSpecifications != null && this._tagSpecifications.Count > 0; } /// /// Gets and sets the property TrafficMirrorFilterId. /// /// The ID of the Traffic Mirror filter. /// /// [AWSProperty(Required=true)] public string TrafficMirrorFilterId { get { return this._trafficMirrorFilterId; } set { this._trafficMirrorFilterId = value; } } // Check to see if TrafficMirrorFilterId property is set internal bool IsSetTrafficMirrorFilterId() { return this._trafficMirrorFilterId != null; } /// /// Gets and sets the property TrafficMirrorTargetId. /// /// The ID of the Traffic Mirror target. /// /// [AWSProperty(Required=true)] public string TrafficMirrorTargetId { get { return this._trafficMirrorTargetId; } set { this._trafficMirrorTargetId = value; } } // Check to see if TrafficMirrorTargetId property is set internal bool IsSetTrafficMirrorTargetId() { return this._trafficMirrorTargetId != null; } /// /// Gets and sets the property VirtualNetworkId. /// /// The VXLAN ID for the Traffic Mirror session. For more information about the VXLAN /// protocol, see RFC 7348. If you do /// not specify a VirtualNetworkId, an account-wide unique id is chosen at /// random. /// /// public int VirtualNetworkId { get { return this._virtualNetworkId.GetValueOrDefault(); } set { this._virtualNetworkId = value; } } // Check to see if VirtualNetworkId property is set internal bool IsSetVirtualNetworkId() { return this._virtualNetworkId.HasValue; } } }