/*
 * 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 ModifyImageAttribute operation.
    /// Modifies the specified attribute of the specified AMI. You can specify only one attribute
    /// at a time.
    /// 
    ///  
    /// 
    /// To specify the attribute, you can use the Attribute parameter, or one
    /// of the following parameters: Description, ImdsSupport, or
    /// LaunchPermission.
    /// 
    ///  
    /// 
    /// Images with an Amazon Web Services Marketplace product code cannot be made public.
    /// 
    ///  
    /// 
    /// To enable the SriovNetSupport enhanced networking attribute of an image, enable SriovNetSupport
    /// on an instance and create an AMI from the instance.
    /// 
    /// 
    public partial class ModifyImageAttributeRequest : AmazonEC2Request
    {
        private string _attribute;
        private string _description;
        private string _imageId;
        private string _imdsSupport;
        private LaunchPermissionModifications _launchPermission;
        private OperationType _operationType;
        private List _organizationalUnitArns = new List();
        private List _organizationArns = new List();
        private List _productCodes = new List();
        private List _userGroups = new List();
        private List _userIds = new List();
        private string _value;
        /// 
        /// Empty constructor used to set  properties independently even when a simple constructor is available
        /// 
        public ModifyImageAttributeRequest() { }
        /// 
        /// Instantiates ModifyImageAttributeRequest with the parameterized properties
        /// 
        /// The ID of the AMI.
        /// The name of the attribute to modify. Valid values: description | imdsSupport | launchPermission 
        public ModifyImageAttributeRequest(string imageId, string attribute)
        {
            _imageId = imageId;
            _attribute = attribute;
        }
        /// 
        /// Gets and sets the property Attribute. 
        /// 
        /// The name of the attribute to modify.
        /// 
        ///  
        /// 
        /// Valid values: description | imdsSupport | launchPermission
        /// 
        /// 
        /// 
        public string Attribute
        {
            get { return this._attribute; }
            set { this._attribute = value; }
        }
        // Check to see if Attribute property is set
        internal bool IsSetAttribute()
        {
            return this._attribute != null;
        }
        /// 
        /// Gets and sets the property Description. 
        /// 
        /// A new description for the AMI.
        /// 
        /// 
        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 ImageId. 
        /// 
        /// The ID of the AMI.
        /// 
        /// 
        [AWSProperty(Required=true)]
        public string ImageId
        {
            get { return this._imageId; }
            set { this._imageId = value; }
        }
        // Check to see if ImageId property is set
        internal bool IsSetImageId()
        {
            return this._imageId != null;
        }
        /// 
        /// Gets and sets the property ImdsSupport. 
        /// 
        /// Set to v2.0 to indicate that IMDSv2 is specified in the AMI. Instances
        /// launched from this AMI will have HttpTokens automatically set to required
        /// so that, by default, the instance requires that IMDSv2 is used when requesting instance
        /// metadata. In addition, HttpPutResponseHopLimit is set to 2.
        /// For more information, see Configure
        /// the AMI in the Amazon EC2 User Guide.
        /// 
        ///   
        /// 
        /// Do not use this parameter unless your AMI software supports IMDSv2. After you set
        /// the value to v2.0, you can't undo it. The only way to “reset” your AMI
        /// is to create a new AMI from the underlying snapshot.
        /// 
        ///  
        /// 
        public string ImdsSupport
        {
            get { return this._imdsSupport; }
            set { this._imdsSupport = value; }
        }
        // Check to see if ImdsSupport property is set
        internal bool IsSetImdsSupport()
        {
            return this._imdsSupport != null;
        }
        /// 
        /// Gets and sets the property LaunchPermission. 
        /// 
        /// A new launch permission for the AMI.
        /// 
        /// 
        public LaunchPermissionModifications LaunchPermission
        {
            get { return this._launchPermission; }
            set { this._launchPermission = value; }
        }
        // Check to see if LaunchPermission property is set
        internal bool IsSetLaunchPermission()
        {
            return this._launchPermission != null;
        }
        /// 
        /// Gets and sets the property OperationType. 
        /// 
        /// The operation type. This parameter can be used only when the Attribute
        /// parameter is launchPermission.
        /// 
        /// 
        public OperationType OperationType
        {
            get { return this._operationType; }
            set { this._operationType = value; }
        }
        // Check to see if OperationType property is set
        internal bool IsSetOperationType()
        {
            return this._operationType != null;
        }
        /// 
        /// Gets and sets the property OrganizationalUnitArns. 
        /// 
        /// The Amazon Resource Name (ARN) of an organizational unit (OU). This parameter can
        /// be used only when the Attribute parameter is launchPermission.
        /// 
        /// 
        public List OrganizationalUnitArns
        {
            get { return this._organizationalUnitArns; }
            set { this._organizationalUnitArns = value; }
        }
        // Check to see if OrganizationalUnitArns property is set
        internal bool IsSetOrganizationalUnitArns()
        {
            return this._organizationalUnitArns != null && this._organizationalUnitArns.Count > 0; 
        }
        /// 
        /// Gets and sets the property OrganizationArns. 
        /// 
        /// The Amazon Resource Name (ARN) of an organization. This parameter can be used only
        /// when the Attribute parameter is launchPermission.
        /// 
        /// 
        public List OrganizationArns
        {
            get { return this._organizationArns; }
            set { this._organizationArns = value; }
        }
        // Check to see if OrganizationArns property is set
        internal bool IsSetOrganizationArns()
        {
            return this._organizationArns != null && this._organizationArns.Count > 0; 
        }
        /// 
        /// Gets and sets the property ProductCodes. 
        /// 
        /// Not supported.
        /// 
        /// 
        public List ProductCodes
        {
            get { return this._productCodes; }
            set { this._productCodes = value; }
        }
        // Check to see if ProductCodes property is set
        internal bool IsSetProductCodes()
        {
            return this._productCodes != null && this._productCodes.Count > 0; 
        }
        /// 
        /// Gets and sets the property UserGroups. 
        /// 
        /// The user groups. This parameter can be used only when the Attribute parameter
        /// is launchPermission.
        /// 
        /// 
        public List UserGroups
        {
            get { return this._userGroups; }
            set { this._userGroups = value; }
        }
        // Check to see if UserGroups property is set
        internal bool IsSetUserGroups()
        {
            return this._userGroups != null && this._userGroups.Count > 0; 
        }
        /// 
        /// Gets and sets the property UserIds. 
        /// 
        /// The Amazon Web Services account IDs. This parameter can be used only when the Attribute
        /// parameter is launchPermission.
        /// 
        /// 
        public List UserIds
        {
            get { return this._userIds; }
            set { this._userIds = value; }
        }
        // Check to see if UserIds property is set
        internal bool IsSetUserIds()
        {
            return this._userIds != null && this._userIds.Count > 0; 
        }
        /// 
        /// Gets and sets the property Value. 
        /// 
        /// The value of the attribute being modified. This parameter can be used only when the
        /// Attribute parameter is description or imdsSupport.
        /// 
        /// 
        public string Value
        {
            get { return this._value; }
            set { this._value = value; }
        }
        // Check to see if Value property is set
        internal bool IsSetValue()
        {
            return this._value != null;
        }
    }
}