Class
ChatGptAccountAnalyticsConverter
IntelligenceX.OpenAI.Usage
Preserves provider field names and unknown measurements in JSON and source-generated protocol consumers.
Inheritance
- JsonConverter<ChatGptAccountAnalytics>
- ChatGptAccountAnalyticsConverter
Constructors
public ChatGptAccountAnalyticsConverter() #Initializes the converter for reflection or source-generated serialization.
Methods
public override ChatGptAccountAnalytics? Read(ref Utf8JsonReader reader, Type typeToConvert, JsonSerializerOptions options) #Reads and converts the JSON to type T.
Parameters
- reader System.Text.Json.Utf8JsonReader
- The reader.
- typeToConvert System.Type
- The type to convert.
- options System.Text.Json.JsonSerializerOptions
- An object that specifies serialization options to use.
public override void Write(Utf8JsonWriter writer, ChatGptAccountAnalytics value, JsonSerializerOptions options) #Writes a specified value as JSON.
Parameters
- writer System.Text.Json.Utf8JsonWriter
- The writer to write to.
- value IntelligenceX.OpenAI.Usage.ChatGptAccountAnalytics
- The value to convert to JSON.
- options System.Text.Json.JsonSerializerOptions
- An object that specifies serialization options to use.
Inherited Methods
public override bool CanConvert(Type typeToConvert) #Inherited from JsonConverter<T>[[ChatGptAccountAnalytics, IntelligenceX, Version=0, Culture=neutral, PublicKeyToken=null]]
Parameters
- typeToConvert Type
Returns
boolpublic virtual ChatGptAccountAnalytics ReadAsPropertyName(ref Utf8JsonReader reader, Type typeToConvert, JsonSerializerOptions options) #Inherited from JsonConverter<T>[[ChatGptAccountAnalytics, IntelligenceX, Version=0, Culture=neutral, PublicKeyToken=null]]
Parameters
- reader Utf8JsonReader
- typeToConvert Type
- options JsonSerializerOptions
Returns
ChatGptAccountAnalyticspublic virtual void WriteAsPropertyName(Utf8JsonWriter writer, ChatGptAccountAnalytics value, JsonSerializerOptions options) #Inherited from JsonConverter<T>[[ChatGptAccountAnalytics, IntelligenceX, Version=0, Culture=neutral, PublicKeyToken=null]]
Parameters
- writer Utf8JsonWriter
- value ChatGptAccountAnalytics
- options JsonSerializerOptions
Inherited Properties
public virtual bool HandleNull { get; } #Inherited from JsonConverter<T>[[ChatGptAccountAnalytics, IntelligenceX, Version=0, Culture=neutral, PublicKeyToken=null]]
public override sealed Type Type { get; } #Inherited from JsonConverter<T>[[ChatGptAccountAnalytics, IntelligenceX, Version=0, Culture=neutral, PublicKeyToken=null]]