//
#nullable disable
using System;
using System.ComponentModel;
using System.Diagnostics.CodeAnalysis;
using OpenAI;
namespace OpenAI.Responses
{
[Experimental("OPENAI001")]
public readonly partial struct ApplyPatchCallStatus : IEquatable
{
private readonly string _value;
private const string InProgressValue = "in_progress";
private const string CompletedValue = "completed";
public ApplyPatchCallStatus(string value)
{
Argument.AssertNotNull(value, nameof(value));
_value = value;
}
public static ApplyPatchCallStatus InProgress { get; } = new ApplyPatchCallStatus(InProgressValue);
public static ApplyPatchCallStatus Completed { get; } = new ApplyPatchCallStatus(CompletedValue);
public static bool operator ==(ApplyPatchCallStatus left, ApplyPatchCallStatus right) => left.Equals(right);
public static bool operator !=(ApplyPatchCallStatus left, ApplyPatchCallStatus right) => !left.Equals(right);
public static implicit operator ApplyPatchCallStatus(string value) => new ApplyPatchCallStatus(value);
public static implicit operator ApplyPatchCallStatus?(string value) => value == null ? null : new ApplyPatchCallStatus(value);
[EditorBrowsable(EditorBrowsableState.Never)]
public override bool Equals(object obj) => obj is ApplyPatchCallStatus other && Equals(other);
public bool Equals(ApplyPatchCallStatus 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;
}
}