< Summary

Class:Azure.Search.Documents.Indexes.Models.SplitSkillLanguage
Assembly:Azure.Search.Documents
File(s):C:\Git\azure-sdk-for-net\sdk\search\Azure.Search.Documents\src\Generated\Models\SplitSkillLanguage.cs
Covered lines:4
Uncovered lines:14
Coverable lines:18
Total lines:72
Line coverage:22.2% (4 of 18)
Covered branches:1
Total branches:6
Branch coverage:16.6% (1 of 6)

Metrics

MethodCyclomatic complexity Line coverage Branch coverage
.ctor(...)-100%50%
get_Da()-0%100%
get_De()-0%100%
get_En()-100%100%
get_Es()-0%100%
get_Fi()-0%100%
get_Fr()-0%100%
get_It()-0%100%
get_Ko()-0%100%
get_Pt()-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\search\Azure.Search.Documents\src\Generated\Models\SplitSkillLanguage.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.Search.Documents.Indexes.Models
 12{
 13    /// <summary> The language codes supported for input text by SplitSkill. </summary>
 14    public readonly partial struct SplitSkillLanguage : IEquatable<SplitSkillLanguage>
 15    {
 16        private readonly string _value;
 17
 18        /// <summary> Determines if two <see cref="SplitSkillLanguage"/> values are the same. </summary>
 19        /// <exception cref="ArgumentNullException"> <paramref name="value"/> is null. </exception>
 20        public SplitSkillLanguage(string value)
 21        {
 1522            _value = value ?? throw new ArgumentNullException(nameof(value));
 1523        }
 24
 25        private const string DaValue = "da";
 26        private const string DeValue = "de";
 27        private const string EnValue = "en";
 28        private const string EsValue = "es";
 29        private const string FiValue = "fi";
 30        private const string FrValue = "fr";
 31        private const string ItValue = "it";
 32        private const string KoValue = "ko";
 33        private const string PtValue = "pt";
 34
 35        /// <summary> Danish. </summary>
 036        public static SplitSkillLanguage Da { get; } = new SplitSkillLanguage(DaValue);
 37        /// <summary> German. </summary>
 038        public static SplitSkillLanguage De { get; } = new SplitSkillLanguage(DeValue);
 39        /// <summary> English. </summary>
 340        public static SplitSkillLanguage En { get; } = new SplitSkillLanguage(EnValue);
 41        /// <summary> Spanish. </summary>
 042        public static SplitSkillLanguage Es { get; } = new SplitSkillLanguage(EsValue);
 43        /// <summary> Finnish. </summary>
 044        public static SplitSkillLanguage Fi { get; } = new SplitSkillLanguage(FiValue);
 45        /// <summary> French. </summary>
 046        public static SplitSkillLanguage Fr { get; } = new SplitSkillLanguage(FrValue);
 47        /// <summary> Italian. </summary>
 048        public static SplitSkillLanguage It { get; } = new SplitSkillLanguage(ItValue);
 49        /// <summary> Korean. </summary>
 050        public static SplitSkillLanguage Ko { get; } = new SplitSkillLanguage(KoValue);
 51        /// <summary> Portuguese. </summary>
 052        public static SplitSkillLanguage Pt { get; } = new SplitSkillLanguage(PtValue);
 53        /// <summary> Determines if two <see cref="SplitSkillLanguage"/> values are the same. </summary>
 054        public static bool operator ==(SplitSkillLanguage left, SplitSkillLanguage right) => left.Equals(right);
 55        /// <summary> Determines if two <see cref="SplitSkillLanguage"/> values are not the same. </summary>
 056        public static bool operator !=(SplitSkillLanguage left, SplitSkillLanguage right) => !left.Equals(right);
 57        /// <summary> Converts a string to a <see cref="SplitSkillLanguage"/>. </summary>
 058        public static implicit operator SplitSkillLanguage(string value) => new SplitSkillLanguage(value);
 59
 60        /// <inheritdoc />
 61        [EditorBrowsable(EditorBrowsableState.Never)]
 062        public override bool Equals(object obj) => obj is SplitSkillLanguage other && Equals(other);
 63        /// <inheritdoc />
 064        public bool Equals(SplitSkillLanguage other) => string.Equals(_value, other._value, StringComparison.InvariantCu
 65
 66        /// <inheritdoc />
 67        [EditorBrowsable(EditorBrowsableState.Never)]
 068        public override int GetHashCode() => _value?.GetHashCode() ?? 0;
 69        /// <inheritdoc />
 470        public override string ToString() => _value;
 71    }
 72}