< Summary

Class:Azure.ResourceManager.Storage.Models.StorageAccountCheckNameAvailabilityParameters
Assembly:Azure.ResourceManager.Storage
File(s):C:\Git\azure-sdk-for-net\sdk\storage\Azure.ResourceManager.Storage\src\Generated\Models\StorageAccountCheckNameAvailabilityParameters.cs
C:\Git\azure-sdk-for-net\sdk\storage\Azure.ResourceManager.Storage\src\Generated\Models\StorageAccountCheckNameAvailabilityParameters.Serialization.cs
Covered lines:14
Uncovered lines:5
Coverable lines:19
Total lines:67
Line coverage:73.6% (14 of 19)
Covered branches:1
Total branches:2
Branch coverage:50% (1 of 2)

Metrics

MethodCyclomatic complexity Line coverage Branch coverage
.ctor(...)-83.33%50%
.ctor(...)-0%100%
get_Name()-100%100%
get_Type()-100%100%
Azure.Core.IUtf8JsonSerializable.Write(...)-100%100%

File(s)

C:\Git\azure-sdk-for-net\sdk\storage\Azure.ResourceManager.Storage\src\Generated\Models\StorageAccountCheckNameAvailabilityParameters.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;
 9
 10namespace Azure.ResourceManager.Storage.Models
 11{
 12    /// <summary> The parameters used to check the availability of the storage account name. </summary>
 13    public partial class StorageAccountCheckNameAvailabilityParameters
 14    {
 15        /// <summary> Initializes a new instance of StorageAccountCheckNameAvailabilityParameters. </summary>
 16        /// <param name="name"> The storage account name. </param>
 1217        public StorageAccountCheckNameAvailabilityParameters(string name)
 18        {
 1219            if (name == null)
 20            {
 021                throw new ArgumentNullException(nameof(name));
 22            }
 23
 1224            Name = name;
 1225            Type = "Microsoft.Storage/storageAccounts";
 1226        }
 27
 28        /// <summary> Initializes a new instance of StorageAccountCheckNameAvailabilityParameters. </summary>
 29        /// <param name="name"> The storage account name. </param>
 30        /// <param name="type"> The type of resource, Microsoft.Storage/storageAccounts. </param>
 031        internal StorageAccountCheckNameAvailabilityParameters(string name, string type)
 32        {
 033            Name = name;
 034            Type = type;
 035        }
 36
 37        /// <summary> The storage account name. </summary>
 1238        public string Name { get; }
 39        /// <summary> The type of resource, Microsoft.Storage/storageAccounts. </summary>
 1240        public string Type { get; }
 41    }
 42}

C:\Git\azure-sdk-for-net\sdk\storage\Azure.ResourceManager.Storage\src\Generated\Models\StorageAccountCheckNameAvailabilityParameters.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.Storage.Models
 12{
 13    public partial class StorageAccountCheckNameAvailabilityParameters : IUtf8JsonSerializable
 14    {
 15        void IUtf8JsonSerializable.Write(Utf8JsonWriter writer)
 16        {
 1217            writer.WriteStartObject();
 1218            writer.WritePropertyName("name");
 1219            writer.WriteStringValue(Name);
 1220            writer.WritePropertyName("type");
 1221            writer.WriteStringValue(Type);
 1222            writer.WriteEndObject();
 1223        }
 24    }
 25}