// <auto-generated/>

#nullable disable

using System;
using System.ComponentModel;

namespace OpenAI.VectorStores
{
    public readonly partial struct VectorStoreBatchFileJobStatus : IEquatable<VectorStoreBatchFileJobStatus>
    {
        private readonly string _value;

        public VectorStoreBatchFileJobStatus(string value)
        {
            _value = value ?? throw new ArgumentNullException(nameof(value));
        }

        private const string InProgressValue = "in_progress";
        private const string CompletedValue = "completed";
        private const string CancelledValue = "cancelled";
        private const string FailedValue = "failed";

        public static VectorStoreBatchFileJobStatus InProgress { get; } = new VectorStoreBatchFileJobStatus(InProgressValue);
        public static VectorStoreBatchFileJobStatus Completed { get; } = new VectorStoreBatchFileJobStatus(CompletedValue);
        public static VectorStoreBatchFileJobStatus Cancelled { get; } = new VectorStoreBatchFileJobStatus(CancelledValue);
        public static VectorStoreBatchFileJobStatus Failed { get; } = new VectorStoreBatchFileJobStatus(FailedValue);
        public static bool operator ==(VectorStoreBatchFileJobStatus left, VectorStoreBatchFileJobStatus right) => left.Equals(right);
        public static bool operator !=(VectorStoreBatchFileJobStatus left, VectorStoreBatchFileJobStatus right) => !left.Equals(right);
        public static implicit operator VectorStoreBatchFileJobStatus(string value) => new VectorStoreBatchFileJobStatus(value);

        [EditorBrowsable(EditorBrowsableState.Never)]
        public override bool Equals(object obj) => obj is VectorStoreBatchFileJobStatus other && Equals(other);
        public bool Equals(VectorStoreBatchFileJobStatus 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;
    }
}
