| | 1 | | // Copyright (c) Microsoft Corporation. All rights reserved. |
| | 2 | | // Licensed under the MIT License. |
| | 3 | |
|
| | 4 | | // <auto-generated/> |
| | 5 | |
|
| | 6 | | #nullable disable |
| | 7 | |
|
| | 8 | | using System; |
| | 9 | | using System.ComponentModel; |
| | 10 | |
|
| | 11 | | namespace Azure.ResourceManager.Network.Models |
| | 12 | | { |
| | 13 | | /// <summary> The IKE encryption algorithm (IKE phase 2). </summary> |
| | 14 | | public readonly partial struct IkeEncryption : IEquatable<IkeEncryption> |
| | 15 | | { |
| | 16 | | private readonly string _value; |
| | 17 | |
|
| | 18 | | /// <summary> Determines if two <see cref="IkeEncryption"/> values are the same. </summary> |
| | 19 | | public IkeEncryption(string value) |
| | 20 | | { |
| 30 | 21 | | _value = value ?? throw new ArgumentNullException(nameof(value)); |
| 30 | 22 | | } |
| | 23 | |
|
| | 24 | | private const string DESValue = "DES"; |
| | 25 | | private const string DES3Value = "DES3"; |
| | 26 | | private const string AES128Value = "AES128"; |
| | 27 | | private const string AES192Value = "AES192"; |
| | 28 | | private const string AES256Value = "AES256"; |
| | 29 | | private const string Gcmaes256Value = "GCMAES256"; |
| | 30 | | private const string Gcmaes128Value = "GCMAES128"; |
| | 31 | |
|
| | 32 | | /// <summary> DES. </summary> |
| 0 | 33 | | public static IkeEncryption DES { get; } = new IkeEncryption(DESValue); |
| | 34 | | /// <summary> DES3. </summary> |
| 0 | 35 | | public static IkeEncryption DES3 { get; } = new IkeEncryption(DES3Value); |
| | 36 | | /// <summary> AES128. </summary> |
| 0 | 37 | | public static IkeEncryption AES128 { get; } = new IkeEncryption(AES128Value); |
| | 38 | | /// <summary> AES192. </summary> |
| 6 | 39 | | public static IkeEncryption AES192 { get; } = new IkeEncryption(AES192Value); |
| | 40 | | /// <summary> AES256. </summary> |
| 6 | 41 | | public static IkeEncryption AES256 { get; } = new IkeEncryption(AES256Value); |
| | 42 | | /// <summary> GCMAES256. </summary> |
| 0 | 43 | | public static IkeEncryption Gcmaes256 { get; } = new IkeEncryption(Gcmaes256Value); |
| | 44 | | /// <summary> GCMAES128. </summary> |
| 0 | 45 | | public static IkeEncryption Gcmaes128 { get; } = new IkeEncryption(Gcmaes128Value); |
| | 46 | | /// <summary> Determines if two <see cref="IkeEncryption"/> values are the same. </summary> |
| 0 | 47 | | public static bool operator ==(IkeEncryption left, IkeEncryption right) => left.Equals(right); |
| | 48 | | /// <summary> Determines if two <see cref="IkeEncryption"/> values are not the same. </summary> |
| 0 | 49 | | public static bool operator !=(IkeEncryption left, IkeEncryption right) => !left.Equals(right); |
| | 50 | | /// <summary> Converts a string to a <see cref="IkeEncryption"/>. </summary> |
| 0 | 51 | | public static implicit operator IkeEncryption(string value) => new IkeEncryption(value); |
| | 52 | |
|
| | 53 | | /// <inheritdoc /> |
| | 54 | | [EditorBrowsable(EditorBrowsableState.Never)] |
| 0 | 55 | | public override bool Equals(object obj) => obj is IkeEncryption other && Equals(other); |
| | 56 | | /// <inheritdoc /> |
| 8 | 57 | | public bool Equals(IkeEncryption other) => string.Equals(_value, other._value, StringComparison.InvariantCulture |
| | 58 | |
|
| | 59 | | /// <inheritdoc /> |
| | 60 | | [EditorBrowsable(EditorBrowsableState.Never)] |
| 0 | 61 | | public override int GetHashCode() => _value?.GetHashCode() ?? 0; |
| | 62 | | /// <inheritdoc /> |
| 16 | 63 | | public override string ToString() => _value; |
| | 64 | | } |
| | 65 | | } |