< Summary

Class:Azure.Analytics.Synapse.Artifacts.Models.WebAnonymousAuthentication
Assembly:Azure.Analytics.Synapse.Artifacts
File(s):C:\Git\azure-sdk-for-net\sdk\synapse\Azure.Analytics.Synapse.Artifacts\src\Generated\Models\WebAnonymousAuthentication.cs
C:\Git\azure-sdk-for-net\sdk\synapse\Azure.Analytics.Synapse.Artifacts\src\Generated\Models\WebAnonymousAuthentication.Serialization.cs
Covered lines:0
Uncovered lines:24
Coverable lines:24
Total lines:81
Line coverage:0% (0 of 24)
Covered branches:0
Total branches:8
Branch coverage:0% (0 of 8)

Metrics

MethodCyclomatic complexity Line coverage Branch coverage
.ctor(...)-0%0%
.ctor(...)-0%100%
Azure.Core.IUtf8JsonSerializable.Write(...)-0%100%
DeserializeWebAnonymousAuthentication(...)-0%0%

File(s)

C:\Git\azure-sdk-for-net\sdk\synapse\Azure.Analytics.Synapse.Artifacts\src\Generated\Models\WebAnonymousAuthentication.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.Analytics.Synapse.Artifacts.Models
 11{
 12    /// <summary> A WebLinkedService that uses anonymous authentication to communicate with an HTTP endpoint. </summary>
 13    public partial class WebAnonymousAuthentication : WebLinkedServiceTypeProperties
 14    {
 15        /// <summary> Initializes a new instance of WebAnonymousAuthentication. </summary>
 16        /// <param name="url"> The URL of the web service endpoint, e.g. http://www.microsoft.com . Type: string (or Exp
 17        /// <exception cref="ArgumentNullException"> <paramref name="url"/> is null. </exception>
 018        public WebAnonymousAuthentication(object url) : base(url)
 19        {
 020            if (url == null)
 21            {
 022                throw new ArgumentNullException(nameof(url));
 23            }
 24
 025            AuthenticationType = WebAuthenticationType.Anonymous;
 026        }
 27
 28        /// <summary> Initializes a new instance of WebAnonymousAuthentication. </summary>
 29        /// <param name="url"> The URL of the web service endpoint, e.g. http://www.microsoft.com . Type: string (or Exp
 30        /// <param name="authenticationType"> Type of authentication used to connect to the web table source. </param>
 031        internal WebAnonymousAuthentication(object url, WebAuthenticationType authenticationType) : base(url, authentica
 32        {
 033            AuthenticationType = authenticationType;
 034        }
 35    }
 36}

C:\Git\azure-sdk-for-net\sdk\synapse\Azure.Analytics.Synapse.Artifacts\src\Generated\Models\WebAnonymousAuthentication.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.Analytics.Synapse.Artifacts.Models
 12{
 13    public partial class WebAnonymousAuthentication : IUtf8JsonSerializable
 14    {
 15        void IUtf8JsonSerializable.Write(Utf8JsonWriter writer)
 16        {
 017            writer.WriteStartObject();
 018            writer.WritePropertyName("url");
 019            writer.WriteObjectValue(Url);
 020            writer.WritePropertyName("authenticationType");
 021            writer.WriteStringValue(AuthenticationType.ToString());
 022            writer.WriteEndObject();
 023        }
 24
 25        internal static WebAnonymousAuthentication DeserializeWebAnonymousAuthentication(JsonElement element)
 26        {
 027            object url = default;
 028            WebAuthenticationType authenticationType = default;
 029            foreach (var property in element.EnumerateObject())
 30            {
 031                if (property.NameEquals("url"))
 32                {
 033                    url = property.Value.GetObject();
 034                    continue;
 35                }
 036                if (property.NameEquals("authenticationType"))
 37                {
 038                    authenticationType = new WebAuthenticationType(property.Value.GetString());
 39                    continue;
 40                }
 41            }
 042            return new WebAnonymousAuthentication(url, authenticationType);
 43        }
 44    }
 45}