// <auto-generated/>

#nullable disable

using System;
using System.ComponentModel;
using OpenAI;

namespace OpenAI.Images
{
    public readonly partial struct GeneratedImageQuality : IEquatable<GeneratedImageQuality>
    {
        private readonly string _value;
        private const string StandardValue = "standard";
        private const string HdValue = "hd";

        public GeneratedImageQuality(string value)
        {
            Argument.AssertNotNull(value, nameof(value));

            _value = value;
        }

        public static GeneratedImageQuality Standard { get; } = new GeneratedImageQuality(StandardValue);

        public static bool operator ==(GeneratedImageQuality left, GeneratedImageQuality right) => left.Equals(right);

        public static bool operator !=(GeneratedImageQuality left, GeneratedImageQuality right) => !left.Equals(right);

        public static implicit operator GeneratedImageQuality(string value) => new GeneratedImageQuality(value);

        [EditorBrowsable(EditorBrowsableState.Never)]
        public override bool Equals(object obj) => obj is GeneratedImageQuality other && Equals(other);

        public bool Equals(GeneratedImageQuality other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase);

        [EditorBrowsable(EditorBrowsableState.Never)]
        public override int GetHashCode() => _value != null ? StringComparer.InvariantCultureIgnoreCase.GetHashCode(_value) : 0;

        public override string ToString() => _value;
    }
}
