< Summary

Class:Azure.ResourceManager.Network.Models.NextHopType
Assembly:Azure.ResourceManager.Network
File(s):C:\Git\azure-sdk-for-net\sdk\network\Azure.ResourceManager.Network\src\Generated\Models\NextHopType.cs
Covered lines:3
Uncovered lines:12
Coverable lines:15
Total lines:62
Line coverage:20% (3 of 15)
Covered branches:1
Total branches:6
Branch coverage:16.6% (1 of 6)

Metrics

MethodCyclomatic complexity Line coverage Branch coverage
.ctor(...)-100%50%
get_Internet()-0%100%
get_VirtualAppliance()-0%100%
get_VirtualNetworkGateway()-0%100%
get_VnetLocal()-0%100%
get_HyperNetGateway()-0%100%
get_None()-0%100%
op_Equality(...)-0%100%
op_Inequality(...)-0%100%
op_Implicit(...)-0%100%
Equals(...)-0%0%
Equals(...)-0%100%
GetHashCode()-0%0%
ToString()-100%100%

File(s)

C:\Git\azure-sdk-for-net\sdk\network\Azure.ResourceManager.Network\src\Generated\Models\NextHopType.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;
 9using System.ComponentModel;
 10
 11namespace Azure.ResourceManager.Network.Models
 12{
 13    /// <summary> Next hop type. </summary>
 14    public readonly partial struct NextHopType : IEquatable<NextHopType>
 15    {
 16        private readonly string _value;
 17
 18        /// <summary> Determines if two <see cref="NextHopType"/> values are the same. </summary>
 19        public NextHopType(string value)
 20        {
 821            _value = value ?? throw new ArgumentNullException(nameof(value));
 822        }
 23
 24        private const string InternetValue = "Internet";
 25        private const string VirtualApplianceValue = "VirtualAppliance";
 26        private const string VirtualNetworkGatewayValue = "VirtualNetworkGateway";
 27        private const string VnetLocalValue = "VnetLocal";
 28        private const string HyperNetGatewayValue = "HyperNetGateway";
 29        private const string NoneValue = "None";
 30
 31        /// <summary> Internet. </summary>
 032        public static NextHopType Internet { get; } = new NextHopType(InternetValue);
 33        /// <summary> VirtualAppliance. </summary>
 034        public static NextHopType VirtualAppliance { get; } = new NextHopType(VirtualApplianceValue);
 35        /// <summary> VirtualNetworkGateway. </summary>
 036        public static NextHopType VirtualNetworkGateway { get; } = new NextHopType(VirtualNetworkGatewayValue);
 37        /// <summary> VnetLocal. </summary>
 038        public static NextHopType VnetLocal { get; } = new NextHopType(VnetLocalValue);
 39        /// <summary> HyperNetGateway. </summary>
 040        public static NextHopType HyperNetGateway { get; } = new NextHopType(HyperNetGatewayValue);
 41        /// <summary> None. </summary>
 042        public static NextHopType None { get; } = new NextHopType(NoneValue);
 43        /// <summary> Determines if two <see cref="NextHopType"/> values are the same. </summary>
 044        public static bool operator ==(NextHopType left, NextHopType right) => left.Equals(right);
 45        /// <summary> Determines if two <see cref="NextHopType"/> values are not the same. </summary>
 046        public static bool operator !=(NextHopType left, NextHopType right) => !left.Equals(right);
 47        /// <summary> Converts a string to a <see cref="NextHopType"/>. </summary>
 048        public static implicit operator NextHopType(string value) => new NextHopType(value);
 49
 50        /// <inheritdoc />
 51        [EditorBrowsable(EditorBrowsableState.Never)]
 052        public override bool Equals(object obj) => obj is NextHopType other && Equals(other);
 53        /// <inheritdoc />
 054        public bool Equals(NextHopType other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIg
 55
 56        /// <inheritdoc />
 57        [EditorBrowsable(EditorBrowsableState.Never)]
 058        public override int GetHashCode() => _value?.GetHashCode() ?? 0;
 59        /// <inheritdoc />
 460        public override string ToString() => _value;
 61    }
 62}