< Summary

Class:Azure.ResourceManager.Network.Models.ApplicationGatewayUrlConfiguration
Assembly:Azure.ResourceManager.Network
File(s):C:\Git\azure-sdk-for-net\sdk\network\Azure.ResourceManager.Network\src\Generated\Models\ApplicationGatewayUrlConfiguration.cs
C:\Git\azure-sdk-for-net\sdk\network\Azure.ResourceManager.Network\src\Generated\Models\ApplicationGatewayUrlConfiguration.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_ModifiedPath()-0%100%
get_ModifiedQueryString()-0%100%
get_Reroute()-0%100%
Azure.Core.IUtf8JsonSerializable.Write(...)-0%0%
DeserializeApplicationGatewayUrlConfiguration(...)-0%0%

File(s)

C:\Git\azure-sdk-for-net\sdk\network\Azure.ResourceManager.Network\src\Generated\Models\ApplicationGatewayUrlConfiguration.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> Url configuration of the Actions set in Application Gateway. </summary>
 11    public partial class ApplicationGatewayUrlConfiguration
 12    {
 13        /// <summary> Initializes a new instance of ApplicationGatewayUrlConfiguration. </summary>
 014        public ApplicationGatewayUrlConfiguration()
 15        {
 016        }
 17
 18        /// <summary> Initializes a new instance of ApplicationGatewayUrlConfiguration. </summary>
 19        /// <param name="modifiedPath"> Url path which user has provided for url rewrite. Null means no path will be upd
 20        /// <param name="modifiedQueryString"> Query string which user has provided for url rewrite. Null means no query
 21        /// <param name="reroute"> If set as true, it will re-evaluate the url path map provided in path based request r
 022        internal ApplicationGatewayUrlConfiguration(string modifiedPath, string modifiedQueryString, bool? reroute)
 23        {
 024            ModifiedPath = modifiedPath;
 025            ModifiedQueryString = modifiedQueryString;
 026            Reroute = reroute;
 027        }
 28
 29        /// <summary> Url path which user has provided for url rewrite. Null means no path will be updated. Default valu
 030        public string ModifiedPath { get; set; }
 31        /// <summary> Query string which user has provided for url rewrite. Null means no query string will be updated. 
 032        public string ModifiedQueryString { get; set; }
 33        /// <summary> If set as true, it will re-evaluate the url path map provided in path based request routing rules 
 034        public bool? Reroute { get; set; }
 35    }
 36}

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