< Summary

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

Metrics

MethodCyclomatic complexity Line coverage Branch coverage
.ctor()-0%100%
.ctor(...)-0%100%
get_Vendor()-0%100%
get_BundledScaleUnit()-0%100%
get_MarketPlaceVersion()-0%100%
Azure.Core.IUtf8JsonSerializable.Write(...)-0%0%
DeserializeVirtualApplianceSkuProperties(...)-0%0%

File(s)

C:\Git\azure-sdk-for-net\sdk\network\Azure.ResourceManager.Network\src\Generated\Models\VirtualApplianceSkuProperties.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 Virtual Appliance Sku Properties. </summary>
 11    public partial class VirtualApplianceSkuProperties
 12    {
 13        /// <summary> Initializes a new instance of VirtualApplianceSkuProperties. </summary>
 014        public VirtualApplianceSkuProperties()
 15        {
 016        }
 17
 18        /// <summary> Initializes a new instance of VirtualApplianceSkuProperties. </summary>
 19        /// <param name="vendor"> Virtual Appliance Vendor. </param>
 20        /// <param name="bundledScaleUnit"> Virtual Appliance Scale Unit. </param>
 21        /// <param name="marketPlaceVersion"> Virtual Appliance Version. </param>
 022        internal VirtualApplianceSkuProperties(string vendor, string bundledScaleUnit, string marketPlaceVersion)
 23        {
 024            Vendor = vendor;
 025            BundledScaleUnit = bundledScaleUnit;
 026            MarketPlaceVersion = marketPlaceVersion;
 027        }
 28
 29        /// <summary> Virtual Appliance Vendor. </summary>
 030        public string Vendor { get; set; }
 31        /// <summary> Virtual Appliance Scale Unit. </summary>
 032        public string BundledScaleUnit { get; set; }
 33        /// <summary> Virtual Appliance Version. </summary>
 034        public string MarketPlaceVersion { get; set; }
 35    }
 36}

C:\Git\azure-sdk-for-net\sdk\network\Azure.ResourceManager.Network\src\Generated\Models\VirtualApplianceSkuProperties.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 VirtualApplianceSkuProperties : IUtf8JsonSerializable
 14    {
 15        void IUtf8JsonSerializable.Write(Utf8JsonWriter writer)
 16        {
 017            writer.WriteStartObject();
 018            if (Vendor != null)
 19            {
 020                writer.WritePropertyName("vendor");
 021                writer.WriteStringValue(Vendor);
 22            }
 023            if (BundledScaleUnit != null)
 24            {
 025                writer.WritePropertyName("bundledScaleUnit");
 026                writer.WriteStringValue(BundledScaleUnit);
 27            }
 028            if (MarketPlaceVersion != null)
 29            {
 030                writer.WritePropertyName("marketPlaceVersion");
 031                writer.WriteStringValue(MarketPlaceVersion);
 32            }
 033            writer.WriteEndObject();
 034        }
 35
 36        internal static VirtualApplianceSkuProperties DeserializeVirtualApplianceSkuProperties(JsonElement element)
 37        {
 038            string vendor = default;
 039            string bundledScaleUnit = default;
 040            string marketPlaceVersion = default;
 041            foreach (var property in element.EnumerateObject())
 42            {
 043                if (property.NameEquals("vendor"))
 44                {
 045                    if (property.Value.ValueKind == JsonValueKind.Null)
 46                    {
 47                        continue;
 48                    }
 049                    vendor = property.Value.GetString();
 050                    continue;
 51                }
 052                if (property.NameEquals("bundledScaleUnit"))
 53                {
 054                    if (property.Value.ValueKind == JsonValueKind.Null)
 55                    {
 56                        continue;
 57                    }
 058                    bundledScaleUnit = property.Value.GetString();
 059                    continue;
 60                }
 061                if (property.NameEquals("marketPlaceVersion"))
 62                {
 063                    if (property.Value.ValueKind == JsonValueKind.Null)
 64                    {
 65                        continue;
 66                    }
 067                    marketPlaceVersion = property.Value.GetString();
 68                    continue;
 69                }
 70            }
 071            return new VirtualApplianceSkuProperties(vendor, bundledScaleUnit, marketPlaceVersion);
 72        }
 73    }
 74}