openai/openai-dotnet

Public

mirrored from https://github.com/openai/openai-dotnetAvailable

CodeCommitsIssuesPull requestsActionsInsightsSecurity
fe4d6cf1ccfea48fa5c2baf67103495ac9b459dd

Branches

Tags

  • No tags available.
0Branches0Tags
Go to file
Add file
Code

Clone

HTTPS

Download ZIP

OpenAI.Responses/src/Generated/Models/ApplyPatchCallOutputStatus.cs

48lines · modecode

1// <auto-generated/>
2
3#nullable disable
4
5using System;
6using System.ComponentModel;
7using System.Diagnostics.CodeAnalysis;
8using OpenAI;
9
10namespace OpenAI.Responses
11{
12 [Experimental("OPENAI001")]
13 public readonly partial struct ApplyPatchCallOutputStatus : IEquatable<ApplyPatchCallOutputStatus>
14 {
15 private readonly string _value;
16 private const string CompletedValue = "completed";
17 private const string FailedValue = "failed";
18
19 public ApplyPatchCallOutputStatus(string value)
20 {
21 Argument.AssertNotNull(value, nameof(value));
22
23 _value = value;
24 }
25
26 public static ApplyPatchCallOutputStatus Completed { get; } = new ApplyPatchCallOutputStatus(CompletedValue);
27
28 public static ApplyPatchCallOutputStatus Failed { get; } = new ApplyPatchCallOutputStatus(FailedValue);
29
30 public static bool operator ==(ApplyPatchCallOutputStatus left, ApplyPatchCallOutputStatus right) => left.Equals(right);
31
32 public static bool operator !=(ApplyPatchCallOutputStatus left, ApplyPatchCallOutputStatus right) => !left.Equals(right);
33
34 public static implicit operator ApplyPatchCallOutputStatus(string value) => new ApplyPatchCallOutputStatus(value);
35
36 public static implicit operator ApplyPatchCallOutputStatus?(string value) => value == null ? null : new ApplyPatchCallOutputStatus(value);
37
38 [EditorBrowsable(EditorBrowsableState.Never)]
39 public override bool Equals(object obj) => obj is ApplyPatchCallOutputStatus other && Equals(other);
40
41 public bool Equals(ApplyPatchCallOutputStatus other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase);
42
43 [EditorBrowsable(EditorBrowsableState.Never)]
44 public override int GetHashCode() => _value != null ? StringComparer.InvariantCultureIgnoreCase.GetHashCode(_value) : 0;
45
46 public override string ToString() => _value;
47 }
48}
49