< Summary

Class:Microsoft.Azure.CognitiveServices.Vision.Face.Models.SnapshotApplyModeEnumExtension
Assembly:Microsoft.Azure.CognitiveServices.Vision.Face
File(s):C:\Git\azure-sdk-for-net\sdk\cognitiveservices\Vision.Face\src\Generated\Models\SnapshotApplyMode.cs
Covered lines:0
Uncovered lines:5
Coverable lines:5
Total lines:54
Line coverage:0% (0 of 5)
Covered branches:0
Total branches:6
Branch coverage:0% (0 of 6)

Metrics

MethodCyclomatic complexity Line coverage Branch coverage
ToSerializedValue(...)-0%0%
ToSerializedValue(...)-0%0%
ParseSnapshotApplyMode(...)-0%0%

File(s)

C:\Git\azure-sdk-for-net\sdk\cognitiveservices\Vision.Face\src\Generated\Models\SnapshotApplyMode.cs

#LineLine coverage
 1// <auto-generated>
 2// Copyright (c) Microsoft Corporation. All rights reserved.
 3// Licensed under the MIT License. See License.txt in the project root for
 4// license information.
 5//
 6// Code generated by Microsoft (R) AutoRest Code Generator.
 7// Changes may cause incorrect behavior and will be lost if the code is
 8// regenerated.
 9// </auto-generated>
 10
 11namespace Microsoft.Azure.CognitiveServices.Vision.Face.Models
 12{
 13    using Newtonsoft.Json;
 14    using Newtonsoft.Json.Converters;
 15    using System.Runtime;
 16    using System.Runtime.Serialization;
 17
 18    /// <summary>
 19    /// Defines values for SnapshotApplyMode.
 20    /// </summary>
 21    [JsonConverter(typeof(StringEnumConverter))]
 22    public enum SnapshotApplyMode
 23    {
 24        [EnumMember(Value = "CreateNew")]
 25        CreateNew
 26    }
 27    internal static class SnapshotApplyModeEnumExtension
 28    {
 29        internal static string ToSerializedValue(this SnapshotApplyMode? value)
 30        {
 031            return value == null ? null : ((SnapshotApplyMode)value).ToSerializedValue();
 32        }
 33
 34        internal static string ToSerializedValue(this SnapshotApplyMode value)
 35        {
 36            switch( value )
 37            {
 38                case SnapshotApplyMode.CreateNew:
 039                    return "CreateNew";
 40            }
 041            return null;
 42        }
 43
 44        internal static SnapshotApplyMode? ParseSnapshotApplyMode(this string value)
 45        {
 46            switch( value )
 47            {
 48                case "CreateNew":
 049                    return SnapshotApplyMode.CreateNew;
 50            }
 051            return null;
 52        }
 53    }
 54}