< Summary

Class:Azure.Iot.Hub.Service.Models.QueryResultType
Assembly:Azure.Iot.Hub.Service
File(s):C:\Git\azure-sdk-for-net\sdk\iot\Azure.Iot.Hub.Service\src\Generated\Models\QueryResultType.cs
Covered lines:0
Uncovered lines:17
Coverable lines:17
Total lines:69
Line coverage:0% (0 of 17)
Covered branches:0
Total branches:6
Branch coverage:0% (0 of 6)

Metrics

MethodCyclomatic complexity Line coverage Branch coverage
.ctor(...)-0%0%
get_Unknown()-0%100%
get_Twin()-0%100%
get_DeviceJob()-0%100%
get_JobResponse()-0%100%
get_Raw()-0%100%
get_Enrollment()-0%100%
get_EnrollmentGroup()-0%100%
get_DeviceRegistration()-0%100%
op_Equality(...)-0%100%
op_Inequality(...)-0%100%
op_Implicit(...)-0%100%
Equals(...)-0%0%
Equals(...)-0%100%
GetHashCode()-0%0%
ToString()-0%100%

File(s)

C:\Git\azure-sdk-for-net\sdk\iot\Azure.Iot.Hub.Service\src\Generated\Models\QueryResultType.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.Iot.Hub.Service.Models
 12{
 13    /// <summary> The query result type. </summary>
 14    public readonly partial struct QueryResultType : IEquatable<QueryResultType>
 15    {
 16        private readonly string _value;
 17
 18        /// <summary> Determines if two <see cref="QueryResultType"/> values are the same. </summary>
 19        /// <exception cref="ArgumentNullException"> <paramref name="value"/> is null. </exception>
 20        public QueryResultType(string value)
 21        {
 022            _value = value ?? throw new ArgumentNullException(nameof(value));
 023        }
 24
 25        private const string UnknownValue = "unknown";
 26        private const string TwinValue = "twin";
 27        private const string DeviceJobValue = "deviceJob";
 28        private const string JobResponseValue = "jobResponse";
 29        private const string RawValue = "raw";
 30        private const string EnrollmentValue = "enrollment";
 31        private const string EnrollmentGroupValue = "enrollmentGroup";
 32        private const string DeviceRegistrationValue = "deviceRegistration";
 33
 34        /// <summary> unknown. </summary>
 035        public static QueryResultType Unknown { get; } = new QueryResultType(UnknownValue);
 36        /// <summary> twin. </summary>
 037        public static QueryResultType Twin { get; } = new QueryResultType(TwinValue);
 38        /// <summary> deviceJob. </summary>
 039        public static QueryResultType DeviceJob { get; } = new QueryResultType(DeviceJobValue);
 40        /// <summary> jobResponse. </summary>
 041        public static QueryResultType JobResponse { get; } = new QueryResultType(JobResponseValue);
 42        /// <summary> raw. </summary>
 043        public static QueryResultType Raw { get; } = new QueryResultType(RawValue);
 44        /// <summary> enrollment. </summary>
 045        public static QueryResultType Enrollment { get; } = new QueryResultType(EnrollmentValue);
 46        /// <summary> enrollmentGroup. </summary>
 047        public static QueryResultType EnrollmentGroup { get; } = new QueryResultType(EnrollmentGroupValue);
 48        /// <summary> deviceRegistration. </summary>
 049        public static QueryResultType DeviceRegistration { get; } = new QueryResultType(DeviceRegistrationValue);
 50        /// <summary> Determines if two <see cref="QueryResultType"/> values are the same. </summary>
 051        public static bool operator ==(QueryResultType left, QueryResultType right) => left.Equals(right);
 52        /// <summary> Determines if two <see cref="QueryResultType"/> values are not the same. </summary>
 053        public static bool operator !=(QueryResultType left, QueryResultType right) => !left.Equals(right);
 54        /// <summary> Converts a string to a <see cref="QueryResultType"/>. </summary>
 055        public static implicit operator QueryResultType(string value) => new QueryResultType(value);
 56
 57        /// <inheritdoc />
 58        [EditorBrowsable(EditorBrowsableState.Never)]
 059        public override bool Equals(object obj) => obj is QueryResultType other && Equals(other);
 60        /// <inheritdoc />
 061        public bool Equals(QueryResultType other) => string.Equals(_value, other._value, StringComparison.InvariantCultu
 62
 63        /// <inheritdoc />
 64        [EditorBrowsable(EditorBrowsableState.Never)]
 065        public override int GetHashCode() => _value?.GetHashCode() ?? 0;
 66        /// <inheritdoc />
 067        public override string ToString() => _value;
 68    }
 69}