Share via


AgentThread.Serialize(JsonSerializerOptions) Method

Definition

Serializes the current object's state to a JsonElement using the specified serialization options.

public virtual System.Text.Json.JsonElement Serialize(System.Text.Json.JsonSerializerOptions? jsonSerializerOptions = default);
abstract member Serialize : System.Text.Json.JsonSerializerOptions -> System.Text.Json.JsonElement
override this.Serialize : System.Text.Json.JsonSerializerOptions -> System.Text.Json.JsonElement
Public Overridable Function Serialize (Optional jsonSerializerOptions As JsonSerializerOptions = Nothing) As JsonElement

Parameters

jsonSerializerOptions
JsonSerializerOptions

The JSON serialization options to use.

Returns

A JsonElement representation of the object's state.

Applies to