< Summary

Class:Azure.ResourceManager.Compute.Models.VirtualMachineScaleSetUpdateOSDisk
Assembly:Azure.ResourceManager.Compute
File(s):C:\Git\azure-sdk-for-net\sdk\compute\Azure.ResourceManager.Compute\src\Generated\Models\VirtualMachineScaleSetUpdateOSDisk.cs
C:\Git\azure-sdk-for-net\sdk\compute\Azure.ResourceManager.Compute\src\Generated\Models\VirtualMachineScaleSetUpdateOSDisk.Serialization.cs
Covered lines:0
Uncovered lines:40
Coverable lines:40
Total lines:106
Line coverage:0% (0 of 40)
Covered branches:0
Total branches:14
Branch coverage:0% (0 of 14)

Metrics

MethodCyclomatic complexity Line coverage Branch coverage
.ctor()-0%100%
.ctor(...)-0%100%
get_Caching()-0%100%
get_WriteAcceleratorEnabled()-0%100%
get_DiskSizeGB()-0%100%
get_Image()-0%100%
get_VhdContainers()-0%100%
get_ManagedDisk()-0%100%
Azure.Core.IUtf8JsonSerializable.Write(...)-0%0%

File(s)

C:\Git\azure-sdk-for-net\sdk\compute\Azure.ResourceManager.Compute\src\Generated\Models\VirtualMachineScaleSetUpdateOSDisk.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.Collections.Generic;
 9
 10namespace Azure.ResourceManager.Compute.Models
 11{
 12    /// <summary> Describes virtual machine scale set operating system disk Update Object. This should be used for Updat
 13    public partial class VirtualMachineScaleSetUpdateOSDisk
 14    {
 15        /// <summary> Initializes a new instance of VirtualMachineScaleSetUpdateOSDisk. </summary>
 016        public VirtualMachineScaleSetUpdateOSDisk()
 17        {
 018        }
 19
 20        /// <summary> Initializes a new instance of VirtualMachineScaleSetUpdateOSDisk. </summary>
 21        /// <param name="caching"> The caching type. </param>
 22        /// <param name="writeAcceleratorEnabled"> Specifies whether writeAccelerator should be enabled or disabled on t
 23        /// <param name="diskSizeGB"> Specifies the size of the operating system disk in gigabytes. This element can be 
 24        /// <param name="image"> The Source User Image VirtualHardDisk. This VirtualHardDisk will be copied before using
 25        /// <param name="vhdContainers"> The list of virtual hard disk container uris. </param>
 26        /// <param name="managedDisk"> The managed disk parameters. </param>
 027        internal VirtualMachineScaleSetUpdateOSDisk(CachingTypes? caching, bool? writeAcceleratorEnabled, int? diskSizeG
 28        {
 029            Caching = caching;
 030            WriteAcceleratorEnabled = writeAcceleratorEnabled;
 031            DiskSizeGB = diskSizeGB;
 032            Image = image;
 033            VhdContainers = vhdContainers;
 034            ManagedDisk = managedDisk;
 035        }
 36
 37        /// <summary> The caching type. </summary>
 038        public CachingTypes? Caching { get; set; }
 39        /// <summary> Specifies whether writeAccelerator should be enabled or disabled on the disk. </summary>
 040        public bool? WriteAcceleratorEnabled { get; set; }
 41        /// <summary> Specifies the size of the operating system disk in gigabytes. This element can be used to overwrit
 042        public int? DiskSizeGB { get; set; }
 43        /// <summary> The Source User Image VirtualHardDisk. This VirtualHardDisk will be copied before using it to atta
 044        public VirtualHardDisk Image { get; set; }
 45        /// <summary> The list of virtual hard disk container uris. </summary>
 046        public IList<string> VhdContainers { get; set; }
 47        /// <summary> The managed disk parameters. </summary>
 048        public VirtualMachineScaleSetManagedDiskParameters ManagedDisk { get; set; }
 49    }
 50}

C:\Git\azure-sdk-for-net\sdk\compute\Azure.ResourceManager.Compute\src\Generated\Models\VirtualMachineScaleSetUpdateOSDisk.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.Compute.Models
 12{
 13    public partial class VirtualMachineScaleSetUpdateOSDisk : IUtf8JsonSerializable
 14    {
 15        void IUtf8JsonSerializable.Write(Utf8JsonWriter writer)
 16        {
 017            writer.WriteStartObject();
 018            if (Caching != null)
 19            {
 020                writer.WritePropertyName("caching");
 021                writer.WriteStringValue(Caching.Value.ToSerialString());
 22            }
 023            if (WriteAcceleratorEnabled != null)
 24            {
 025                writer.WritePropertyName("writeAcceleratorEnabled");
 026                writer.WriteBooleanValue(WriteAcceleratorEnabled.Value);
 27            }
 028            if (DiskSizeGB != null)
 29            {
 030                writer.WritePropertyName("diskSizeGB");
 031                writer.WriteNumberValue(DiskSizeGB.Value);
 32            }
 033            if (Image != null)
 34            {
 035                writer.WritePropertyName("image");
 036                writer.WriteObjectValue(Image);
 37            }
 038            if (VhdContainers != null)
 39            {
 040                writer.WritePropertyName("vhdContainers");
 041                writer.WriteStartArray();
 042                foreach (var item in VhdContainers)
 43                {
 044                    writer.WriteStringValue(item);
 45                }
 046                writer.WriteEndArray();
 47            }
 048            if (ManagedDisk != null)
 49            {
 050                writer.WritePropertyName("managedDisk");
 051                writer.WriteObjectValue(ManagedDisk);
 52            }
 053            writer.WriteEndObject();
 054        }
 55    }
 56}