< Summary

Class:Azure.ResourceManager.Network.Models.NetworkSecurityRulesEvaluationResult
Assembly:Azure.ResourceManager.Network
File(s):C:\Git\azure-sdk-for-net\sdk\network\Azure.ResourceManager.Network\src\Generated\Models\NetworkSecurityRulesEvaluationResult.cs
C:\Git\azure-sdk-for-net\sdk\network\Azure.ResourceManager.Network\src\Generated\Models\NetworkSecurityRulesEvaluationResult.Serialization.cs
Covered lines:0
Uncovered lines:47
Coverable lines:47
Total lines:131
Line coverage:0% (0 of 47)
Covered branches:0
Total branches:26
Branch coverage:0% (0 of 26)

Metrics

MethodCyclomatic complexity Line coverage Branch coverage
.ctor()-0%100%
.ctor(...)-0%100%
get_Name()-0%100%
get_ProtocolMatched()-0%100%
get_SourceMatched()-0%100%
get_SourcePortMatched()-0%100%
get_DestinationMatched()-0%100%
get_DestinationPortMatched()-0%100%
DeserializeNetworkSecurityRulesEvaluationResult(...)-0%0%

File(s)

C:\Git\azure-sdk-for-net\sdk\network\Azure.ResourceManager.Network\src\Generated\Models\NetworkSecurityRulesEvaluationResult.cs

#LineLine coverage
 1// Copyright (c) Microsoft Corporation. All rights reserved.
 2// Licensed under the MIT License.
 3
 4// <auto-generated/>
 5
 6#nullable disable
 7
 8namespace Azure.ResourceManager.Network.Models
 9{
 10    /// <summary> Network security rules evaluation result. </summary>
 11    public partial class NetworkSecurityRulesEvaluationResult
 12    {
 13        /// <summary> Initializes a new instance of NetworkSecurityRulesEvaluationResult. </summary>
 014        internal NetworkSecurityRulesEvaluationResult()
 15        {
 016        }
 17
 18        /// <summary> Initializes a new instance of NetworkSecurityRulesEvaluationResult. </summary>
 19        /// <param name="name"> Name of the network security rule. </param>
 20        /// <param name="protocolMatched"> Value indicating whether protocol is matched. </param>
 21        /// <param name="sourceMatched"> Value indicating whether source is matched. </param>
 22        /// <param name="sourcePortMatched"> Value indicating whether source port is matched. </param>
 23        /// <param name="destinationMatched"> Value indicating whether destination is matched. </param>
 24        /// <param name="destinationPortMatched"> Value indicating whether destination port is matched. </param>
 025        internal NetworkSecurityRulesEvaluationResult(string name, bool? protocolMatched, bool? sourceMatched, bool? sou
 26        {
 027            Name = name;
 028            ProtocolMatched = protocolMatched;
 029            SourceMatched = sourceMatched;
 030            SourcePortMatched = sourcePortMatched;
 031            DestinationMatched = destinationMatched;
 032            DestinationPortMatched = destinationPortMatched;
 033        }
 34
 35        /// <summary> Name of the network security rule. </summary>
 036        public string Name { get; }
 37        /// <summary> Value indicating whether protocol is matched. </summary>
 038        public bool? ProtocolMatched { get; }
 39        /// <summary> Value indicating whether source is matched. </summary>
 040        public bool? SourceMatched { get; }
 41        /// <summary> Value indicating whether source port is matched. </summary>
 042        public bool? SourcePortMatched { get; }
 43        /// <summary> Value indicating whether destination is matched. </summary>
 044        public bool? DestinationMatched { get; }
 45        /// <summary> Value indicating whether destination port is matched. </summary>
 046        public bool? DestinationPortMatched { get; }
 47    }
 48}

C:\Git\azure-sdk-for-net\sdk\network\Azure.ResourceManager.Network\src\Generated\Models\NetworkSecurityRulesEvaluationResult.Serialization.cs

#LineLine coverage
 1// Copyright (c) Microsoft Corporation. All rights reserved.
 2// Licensed under the MIT License.
 3
 4// <auto-generated/>
 5
 6#nullable disable
 7
 8using System.Text.Json;
 9using Azure.Core;
 10
 11namespace Azure.ResourceManager.Network.Models
 12{
 13    public partial class NetworkSecurityRulesEvaluationResult
 14    {
 15        internal static NetworkSecurityRulesEvaluationResult DeserializeNetworkSecurityRulesEvaluationResult(JsonElement
 16        {
 017            string name = default;
 018            bool? protocolMatched = default;
 019            bool? sourceMatched = default;
 020            bool? sourcePortMatched = default;
 021            bool? destinationMatched = default;
 022            bool? destinationPortMatched = default;
 023            foreach (var property in element.EnumerateObject())
 24            {
 025                if (property.NameEquals("name"))
 26                {
 027                    if (property.Value.ValueKind == JsonValueKind.Null)
 28                    {
 29                        continue;
 30                    }
 031                    name = property.Value.GetString();
 032                    continue;
 33                }
 034                if (property.NameEquals("protocolMatched"))
 35                {
 036                    if (property.Value.ValueKind == JsonValueKind.Null)
 37                    {
 38                        continue;
 39                    }
 040                    protocolMatched = property.Value.GetBoolean();
 041                    continue;
 42                }
 043                if (property.NameEquals("sourceMatched"))
 44                {
 045                    if (property.Value.ValueKind == JsonValueKind.Null)
 46                    {
 47                        continue;
 48                    }
 049                    sourceMatched = property.Value.GetBoolean();
 050                    continue;
 51                }
 052                if (property.NameEquals("sourcePortMatched"))
 53                {
 054                    if (property.Value.ValueKind == JsonValueKind.Null)
 55                    {
 56                        continue;
 57                    }
 058                    sourcePortMatched = property.Value.GetBoolean();
 059                    continue;
 60                }
 061                if (property.NameEquals("destinationMatched"))
 62                {
 063                    if (property.Value.ValueKind == JsonValueKind.Null)
 64                    {
 65                        continue;
 66                    }
 067                    destinationMatched = property.Value.GetBoolean();
 068                    continue;
 69                }
 070                if (property.NameEquals("destinationPortMatched"))
 71                {
 072                    if (property.Value.ValueKind == JsonValueKind.Null)
 73                    {
 74                        continue;
 75                    }
 076                    destinationPortMatched = property.Value.GetBoolean();
 77                    continue;
 78                }
 79            }
 080            return new NetworkSecurityRulesEvaluationResult(name, protocolMatched, sourceMatched, sourcePortMatched, des
 81        }
 82    }
 83}