< Summary

Class:Azure.Security.KeyVault.Administration.Models.SASTokenParameter
Assembly:Azure.Security.KeyVault.Administration
File(s):C:\Git\azure-sdk-for-net\sdk\keyvault\Azure.Security.KeyVault.Administration\src\Generated\Models\SASTokenParameter.cs
C:\Git\azure-sdk-for-net\sdk\keyvault\Azure.Security.KeyVault.Administration\src\Generated\Models\SASTokenParameter.Serialization.cs
Covered lines:15
Uncovered lines:2
Coverable lines:17
Total lines:64
Line coverage:88.2% (15 of 17)
Covered branches:2
Total branches:4
Branch coverage:50% (2 of 4)

Metrics

MethodCyclomatic complexity Line coverage Branch coverage
.ctor(...)-75%50%
get_StorageResourceUri()-100%100%
get_Token()-100%100%
Azure.Core.IUtf8JsonSerializable.Write(...)-100%100%

File(s)

C:\Git\azure-sdk-for-net\sdk\keyvault\Azure.Security.KeyVault.Administration\src\Generated\Models\SASTokenParameter.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.Security.KeyVault.Administration.Models
 11{
 12    /// <summary> The SASTokenParameter. </summary>
 13    internal partial class SASTokenParameter
 14    {
 15        /// <summary> Initializes a new instance of SASTokenParameter. </summary>
 16        /// <param name="storageResourceUri"> Azure Blob storage container Uri. </param>
 17        /// <param name="token"> The SAS token pointing to an Azure Blob storage container. </param>
 18        /// <exception cref="ArgumentNullException"> <paramref name="storageResourceUri"/> or <paramref name="token"/> i
 819        public SASTokenParameter(string storageResourceUri, string token)
 20        {
 821            if (storageResourceUri == null)
 22            {
 023                throw new ArgumentNullException(nameof(storageResourceUri));
 24            }
 825            if (token == null)
 26            {
 027                throw new ArgumentNullException(nameof(token));
 28            }
 29
 830            StorageResourceUri = storageResourceUri;
 831            Token = token;
 832        }
 33
 34        /// <summary> Azure Blob storage container Uri. </summary>
 835        public string StorageResourceUri { get; }
 36        /// <summary> The SAS token pointing to an Azure Blob storage container. </summary>
 837        public string Token { get; }
 38    }
 39}

C:\Git\azure-sdk-for-net\sdk\keyvault\Azure.Security.KeyVault.Administration\src\Generated\Models\SASTokenParameter.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.Security.KeyVault.Administration.Models
 12{
 13    internal partial class SASTokenParameter : IUtf8JsonSerializable
 14    {
 15        void IUtf8JsonSerializable.Write(Utf8JsonWriter writer)
 16        {
 817            writer.WriteStartObject();
 818            writer.WritePropertyName("storageResourceUri");
 819            writer.WriteStringValue(StorageResourceUri);
 820            writer.WritePropertyName("token");
 821            writer.WriteStringValue(Token);
 822            writer.WriteEndObject();
 823        }
 24    }
 25}