< Summary

Class:Azure.ResourceManager.Network.Models.ExpressRouteCircuitConnection
Assembly:Azure.ResourceManager.Network
File(s):C:\Git\azure-sdk-for-net\sdk\network\Azure.ResourceManager.Network\src\Generated\Models\ExpressRouteCircuitConnection.cs
C:\Git\azure-sdk-for-net\sdk\network\Azure.ResourceManager.Network\src\Generated\Models\ExpressRouteCircuitConnection.Serialization.cs
Covered lines:0
Uncovered lines:121
Coverable lines:121
Total lines:269
Line coverage:0% (0 of 121)
Covered branches:0
Total branches:72
Branch coverage:0% (0 of 72)

Metrics

MethodCyclomatic complexity Line coverage Branch coverage
.ctor()-0%100%
.ctor(...)-0%100%
get_Name()-0%100%
get_Etag()-0%100%
get_Type()-0%100%
get_ExpressRouteCircuitPeering()-0%100%
get_PeerExpressRouteCircuitPeering()-0%100%
get_AddressPrefix()-0%100%
get_AuthorizationKey()-0%100%
get_Ipv6CircuitConnectionConfig()-0%100%
get_CircuitConnectionStatus()-0%100%
get_ProvisioningState()-0%100%
Azure.Core.IUtf8JsonSerializable.Write(...)-0%0%
DeserializeExpressRouteCircuitConnection(...)-0%0%

File(s)

C:\Git\azure-sdk-for-net\sdk\network\Azure.ResourceManager.Network\src\Generated\Models\ExpressRouteCircuitConnection.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> Express Route Circuit Connection in an ExpressRouteCircuitPeering resource. </summary>
 11    public partial class ExpressRouteCircuitConnection : SubResource
 12    {
 13        /// <summary> Initializes a new instance of ExpressRouteCircuitConnection. </summary>
 014        public ExpressRouteCircuitConnection()
 15        {
 016        }
 17
 18        /// <summary> Initializes a new instance of ExpressRouteCircuitConnection. </summary>
 19        /// <param name="id"> Resource ID. </param>
 20        /// <param name="name"> The name of the resource that is unique within a resource group. This name can be used t
 21        /// <param name="etag"> A unique read-only string that changes whenever the resource is updated. </param>
 22        /// <param name="type"> Type of the resource. </param>
 23        /// <param name="expressRouteCircuitPeering"> Reference to Express Route Circuit Private Peering Resource of the
 24        /// <param name="peerExpressRouteCircuitPeering"> Reference to Express Route Circuit Private Peering Resource of
 25        /// <param name="addressPrefix"> /29 IP address space to carve out Customer addresses for tunnels. </param>
 26        /// <param name="authorizationKey"> The authorization key. </param>
 27        /// <param name="ipv6CircuitConnectionConfig"> IPv6 Address PrefixProperties of the express route circuit connec
 28        /// <param name="circuitConnectionStatus"> Express Route Circuit connection state. </param>
 29        /// <param name="provisioningState"> The provisioning state of the express route circuit connection resource. </
 030        internal ExpressRouteCircuitConnection(string id, string name, string etag, string type, SubResource expressRout
 31        {
 032            Name = name;
 033            Etag = etag;
 034            Type = type;
 035            ExpressRouteCircuitPeering = expressRouteCircuitPeering;
 036            PeerExpressRouteCircuitPeering = peerExpressRouteCircuitPeering;
 037            AddressPrefix = addressPrefix;
 038            AuthorizationKey = authorizationKey;
 039            Ipv6CircuitConnectionConfig = ipv6CircuitConnectionConfig;
 040            CircuitConnectionStatus = circuitConnectionStatus;
 041            ProvisioningState = provisioningState;
 042        }
 43
 44        /// <summary> The name of the resource that is unique within a resource group. This name can be used to access t
 045        public string Name { get; set; }
 46        /// <summary> A unique read-only string that changes whenever the resource is updated. </summary>
 047        public string Etag { get; }
 48        /// <summary> Type of the resource. </summary>
 049        public string Type { get; }
 50        /// <summary> Reference to Express Route Circuit Private Peering Resource of the circuit initiating connection. 
 051        public SubResource ExpressRouteCircuitPeering { get; set; }
 52        /// <summary> Reference to Express Route Circuit Private Peering Resource of the peered circuit. </summary>
 053        public SubResource PeerExpressRouteCircuitPeering { get; set; }
 54        /// <summary> /29 IP address space to carve out Customer addresses for tunnels. </summary>
 055        public string AddressPrefix { get; set; }
 56        /// <summary> The authorization key. </summary>
 057        public string AuthorizationKey { get; set; }
 58        /// <summary> IPv6 Address PrefixProperties of the express route circuit connection. </summary>
 059        public Ipv6CircuitConnectionConfig Ipv6CircuitConnectionConfig { get; set; }
 60        /// <summary> Express Route Circuit connection state. </summary>
 061        public CircuitConnectionStatus? CircuitConnectionStatus { get; }
 62        /// <summary> The provisioning state of the express route circuit connection resource. </summary>
 063        public ProvisioningState? ProvisioningState { get; }
 64    }
 65}

C:\Git\azure-sdk-for-net\sdk\network\Azure.ResourceManager.Network\src\Generated\Models\ExpressRouteCircuitConnection.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 ExpressRouteCircuitConnection : IUtf8JsonSerializable
 14    {
 15        void IUtf8JsonSerializable.Write(Utf8JsonWriter writer)
 16        {
 017            writer.WriteStartObject();
 018            if (Name != null)
 19            {
 020                writer.WritePropertyName("name");
 021                writer.WriteStringValue(Name);
 22            }
 023            if (Etag != null)
 24            {
 025                writer.WritePropertyName("etag");
 026                writer.WriteStringValue(Etag);
 27            }
 028            if (Type != null)
 29            {
 030                writer.WritePropertyName("type");
 031                writer.WriteStringValue(Type);
 32            }
 033            if (Id != null)
 34            {
 035                writer.WritePropertyName("id");
 036                writer.WriteStringValue(Id);
 37            }
 038            writer.WritePropertyName("properties");
 039            writer.WriteStartObject();
 040            if (ExpressRouteCircuitPeering != null)
 41            {
 042                writer.WritePropertyName("expressRouteCircuitPeering");
 043                writer.WriteObjectValue(ExpressRouteCircuitPeering);
 44            }
 045            if (PeerExpressRouteCircuitPeering != null)
 46            {
 047                writer.WritePropertyName("peerExpressRouteCircuitPeering");
 048                writer.WriteObjectValue(PeerExpressRouteCircuitPeering);
 49            }
 050            if (AddressPrefix != null)
 51            {
 052                writer.WritePropertyName("addressPrefix");
 053                writer.WriteStringValue(AddressPrefix);
 54            }
 055            if (AuthorizationKey != null)
 56            {
 057                writer.WritePropertyName("authorizationKey");
 058                writer.WriteStringValue(AuthorizationKey);
 59            }
 060            if (Ipv6CircuitConnectionConfig != null)
 61            {
 062                writer.WritePropertyName("ipv6CircuitConnectionConfig");
 063                writer.WriteObjectValue(Ipv6CircuitConnectionConfig);
 64            }
 065            if (CircuitConnectionStatus != null)
 66            {
 067                writer.WritePropertyName("circuitConnectionStatus");
 068                writer.WriteStringValue(CircuitConnectionStatus.Value.ToString());
 69            }
 070            if (ProvisioningState != null)
 71            {
 072                writer.WritePropertyName("provisioningState");
 073                writer.WriteStringValue(ProvisioningState.Value.ToString());
 74            }
 075            writer.WriteEndObject();
 076            writer.WriteEndObject();
 077        }
 78
 79        internal static ExpressRouteCircuitConnection DeserializeExpressRouteCircuitConnection(JsonElement element)
 80        {
 081            string name = default;
 082            string etag = default;
 083            string type = default;
 084            string id = default;
 085            SubResource expressRouteCircuitPeering = default;
 086            SubResource peerExpressRouteCircuitPeering = default;
 087            string addressPrefix = default;
 088            string authorizationKey = default;
 089            Ipv6CircuitConnectionConfig ipv6CircuitConnectionConfig = default;
 090            CircuitConnectionStatus? circuitConnectionStatus = default;
 091            ProvisioningState? provisioningState = default;
 092            foreach (var property in element.EnumerateObject())
 93            {
 094                if (property.NameEquals("name"))
 95                {
 096                    if (property.Value.ValueKind == JsonValueKind.Null)
 97                    {
 98                        continue;
 99                    }
 0100                    name = property.Value.GetString();
 0101                    continue;
 102                }
 0103                if (property.NameEquals("etag"))
 104                {
 0105                    if (property.Value.ValueKind == JsonValueKind.Null)
 106                    {
 107                        continue;
 108                    }
 0109                    etag = property.Value.GetString();
 0110                    continue;
 111                }
 0112                if (property.NameEquals("type"))
 113                {
 0114                    if (property.Value.ValueKind == JsonValueKind.Null)
 115                    {
 116                        continue;
 117                    }
 0118                    type = property.Value.GetString();
 0119                    continue;
 120                }
 0121                if (property.NameEquals("id"))
 122                {
 0123                    if (property.Value.ValueKind == JsonValueKind.Null)
 124                    {
 125                        continue;
 126                    }
 0127                    id = property.Value.GetString();
 0128                    continue;
 129                }
 0130                if (property.NameEquals("properties"))
 131                {
 0132                    foreach (var property0 in property.Value.EnumerateObject())
 133                    {
 0134                        if (property0.NameEquals("expressRouteCircuitPeering"))
 135                        {
 0136                            if (property0.Value.ValueKind == JsonValueKind.Null)
 137                            {
 138                                continue;
 139                            }
 0140                            expressRouteCircuitPeering = DeserializeSubResource(property0.Value);
 0141                            continue;
 142                        }
 0143                        if (property0.NameEquals("peerExpressRouteCircuitPeering"))
 144                        {
 0145                            if (property0.Value.ValueKind == JsonValueKind.Null)
 146                            {
 147                                continue;
 148                            }
 0149                            peerExpressRouteCircuitPeering = DeserializeSubResource(property0.Value);
 0150                            continue;
 151                        }
 0152                        if (property0.NameEquals("addressPrefix"))
 153                        {
 0154                            if (property0.Value.ValueKind == JsonValueKind.Null)
 155                            {
 156                                continue;
 157                            }
 0158                            addressPrefix = property0.Value.GetString();
 0159                            continue;
 160                        }
 0161                        if (property0.NameEquals("authorizationKey"))
 162                        {
 0163                            if (property0.Value.ValueKind == JsonValueKind.Null)
 164                            {
 165                                continue;
 166                            }
 0167                            authorizationKey = property0.Value.GetString();
 0168                            continue;
 169                        }
 0170                        if (property0.NameEquals("ipv6CircuitConnectionConfig"))
 171                        {
 0172                            if (property0.Value.ValueKind == JsonValueKind.Null)
 173                            {
 174                                continue;
 175                            }
 0176                            ipv6CircuitConnectionConfig = Ipv6CircuitConnectionConfig.DeserializeIpv6CircuitConnectionCo
 0177                            continue;
 178                        }
 0179                        if (property0.NameEquals("circuitConnectionStatus"))
 180                        {
 0181                            if (property0.Value.ValueKind == JsonValueKind.Null)
 182                            {
 183                                continue;
 184                            }
 0185                            circuitConnectionStatus = new CircuitConnectionStatus(property0.Value.GetString());
 0186                            continue;
 187                        }
 0188                        if (property0.NameEquals("provisioningState"))
 189                        {
 0190                            if (property0.Value.ValueKind == JsonValueKind.Null)
 191                            {
 192                                continue;
 193                            }
 0194                            provisioningState = new ProvisioningState(property0.Value.GetString());
 195                            continue;
 196                        }
 197                    }
 198                    continue;
 199                }
 200            }
 0201            return new ExpressRouteCircuitConnection(id, name, etag, type, expressRouteCircuitPeering, peerExpressRouteC
 202        }
 203    }
 204}