< Summary

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

Metrics

MethodCyclomatic complexity Line coverage Branch coverage
.ctor()-100%100%
.ctor(...)-100%100%
get_DomainNameLabel()-100%100%
get_Fqdn()-100%100%
get_ReverseFqdn()-100%100%
Azure.Core.IUtf8JsonSerializable.Write(...)-100%100%
DeserializePublicIPAddressDnsSettings(...)-100%100%

File(s)

C:\Git\azure-sdk-for-net\sdk\network\Azure.ResourceManager.Network\src\Generated\Models\PublicIPAddressDnsSettings.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> Contains FQDN of the DNS record associated with the public IP address. </summary>
 11    public partial class PublicIPAddressDnsSettings
 12    {
 13        /// <summary> Initializes a new instance of PublicIPAddressDnsSettings. </summary>
 5614        public PublicIPAddressDnsSettings()
 15        {
 5616        }
 17
 18        /// <summary> Initializes a new instance of PublicIPAddressDnsSettings. </summary>
 19        /// <param name="domainNameLabel"> The domain name label. The concatenation of the domain name label and the reg
 20        /// <param name="fqdn"> The Fully Qualified Domain Name of the A DNS record associated with the public IP. This 
 21        /// <param name="reverseFqdn"> The reverse FQDN. A user-visible, fully qualified domain name that resolves to th
 22822        internal PublicIPAddressDnsSettings(string domainNameLabel, string fqdn, string reverseFqdn)
 23        {
 22824            DomainNameLabel = domainNameLabel;
 22825            Fqdn = fqdn;
 22826            ReverseFqdn = reverseFqdn;
 22827        }
 28
 29        /// <summary> The domain name label. The concatenation of the domain name label and the regionalized DNS zone ma
 54830        public string DomainNameLabel { get; set; }
 31        /// <summary> The Fully Qualified Domain Name of the A DNS record associated with the public IP. This is the con
 38432        public string Fqdn { get; set; }
 33        /// <summary> The reverse FQDN. A user-visible, fully qualified domain name that resolves to this public IP addr
 36434        public string ReverseFqdn { get; set; }
 35    }
 36}

C:\Git\azure-sdk-for-net\sdk\network\Azure.ResourceManager.Network\src\Generated\Models\PublicIPAddressDnsSettings.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 PublicIPAddressDnsSettings : IUtf8JsonSerializable
 14    {
 15        void IUtf8JsonSerializable.Write(Utf8JsonWriter writer)
 16        {
 12017            writer.WriteStartObject();
 12018            if (DomainNameLabel != null)
 19            {
 12020                writer.WritePropertyName("domainNameLabel");
 12021                writer.WriteStringValue(DomainNameLabel);
 22            }
 12023            if (Fqdn != null)
 24            {
 825                writer.WritePropertyName("fqdn");
 826                writer.WriteStringValue(Fqdn);
 27            }
 12028            if (ReverseFqdn != null)
 29            {
 830                writer.WritePropertyName("reverseFqdn");
 831                writer.WriteStringValue(ReverseFqdn);
 32            }
 12033            writer.WriteEndObject();
 12034        }
 35
 36        internal static PublicIPAddressDnsSettings DeserializePublicIPAddressDnsSettings(JsonElement element)
 37        {
 22838            string domainNameLabel = default;
 22839            string fqdn = default;
 22840            string reverseFqdn = default;
 140041            foreach (var property in element.EnumerateObject())
 42            {
 47243                if (property.NameEquals("domainNameLabel"))
 44                {
 22845                    if (property.Value.ValueKind == JsonValueKind.Null)
 46                    {
 47                        continue;
 48                    }
 22849                    domainNameLabel = property.Value.GetString();
 22850                    continue;
 51                }
 24452                if (property.NameEquals("fqdn"))
 53                {
 22854                    if (property.Value.ValueKind == JsonValueKind.Null)
 55                    {
 56                        continue;
 57                    }
 22858                    fqdn = property.Value.GetString();
 22859                    continue;
 60                }
 1661                if (property.NameEquals("reverseFqdn"))
 62                {
 1663                    if (property.Value.ValueKind == JsonValueKind.Null)
 64                    {
 65                        continue;
 66                    }
 1667                    reverseFqdn = property.Value.GetString();
 68                    continue;
 69                }
 70            }
 22871            return new PublicIPAddressDnsSettings(domainNameLabel, fqdn, reverseFqdn);
 72        }
 73    }
 74}