// *** WARNING: this file was generated by pulumigen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***

using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Threading.Tasks;
using Pulumi.Serialization;

namespace Pulumi.ScalewayInstances.Rules.Outputs
{

    [OutputType]
    public sealed class ScalewayInstanceV1SetSecurityGroupRulesRequestRule
    {
        /// <summary>
        /// Action to apply when the rule matches a packet
        /// </summary>
        public readonly Pulumi.ScalewayInstances.Rules.ScalewayInstanceV1SetSecurityGroupRulesRequestRuleAction? Action;
        /// <summary>
        /// Beginning of the range of ports this rule applies to (inclusive). This value will be set to null if protocol is ICMP or ANY
        /// </summary>
        public readonly double? Dest_port_from;
        /// <summary>
        /// End of the range of ports this rule applies to (inclusive). This value will be set to null if protocol is ICMP or ANY, or if it is equal to dest_port_from
        /// </summary>
        public readonly double? Dest_port_to;
        /// <summary>
        /// Direction the rule applies to
        /// </summary>
        public readonly Pulumi.ScalewayInstances.Rules.ScalewayInstanceV1SetSecurityGroupRulesRequestRuleDirection? Direction;
        /// <summary>
        /// Indicates if this rule is editable. Rules with the value false will be ignored
        /// </summary>
        public readonly bool? Editable;
        /// <summary>
        /// UUID of the security rule to update. If no value is provided, a new rule will be created
        /// </summary>
        public readonly string? Id;
        /// <summary>
        /// The range of IP address this rules applies to (IP network)
        /// </summary>
        public readonly string? Ip_range;
        /// <summary>
        /// Position of this rule in the security group rules list. If several rules are passed with the same position, the resulting order is undefined
        /// </summary>
        public readonly double? Position;
        /// <summary>
        /// Protocol family this rule applies to
        /// </summary>
        public readonly Pulumi.ScalewayInstances.Rules.ScalewayInstanceV1SetSecurityGroupRulesRequestRuleProtocol? Protocol;
        /// <summary>
        /// Zone of the rule. This field is ignored
        /// </summary>
        public readonly string? Zone;

        [OutputConstructor]
        private ScalewayInstanceV1SetSecurityGroupRulesRequestRule(
            Pulumi.ScalewayInstances.Rules.ScalewayInstanceV1SetSecurityGroupRulesRequestRuleAction? action,

            double? dest_port_from,

            double? dest_port_to,

            Pulumi.ScalewayInstances.Rules.ScalewayInstanceV1SetSecurityGroupRulesRequestRuleDirection? direction,

            bool? editable,

            string? id,

            string? ip_range,

            double? position,

            Pulumi.ScalewayInstances.Rules.ScalewayInstanceV1SetSecurityGroupRulesRequestRuleProtocol? protocol,

            string? zone)
        {
            Action = action;
            Dest_port_from = dest_port_from;
            Dest_port_to = dest_port_to;
            Direction = direction;
            Editable = editable;
            Id = id;
            Ip_range = ip_range;
            Position = position;
            Protocol = protocol;
            Zone = zone;
        }
    }
}
