Show / Hide Table of Contents

Class TransactionTypeNameConverter

Reads the TransactionType field into its name, by the rules of TransactionTypeConverter for everything but a string: a number becomes the member's name, and a JSON null or any other token raises System.Text.Json.JsonException.

Inheritance
object
JsonConverter
JsonConverter<string>
TransactionTypeNameConverter
Namespace: Xrpl.Client.Json.Converters
Assembly: Xrpl.dll
Syntax
public class TransactionTypeNameConverter : JsonConverter<string>

Properties

| Edit this page View Source

HandleNull

Gets a value that indicates whether null should be passed to the converter on serialization, and whether System.Text.Json.JsonTokenType.Null should be passed on deserialization.

Declaration
public override bool HandleNull { get; }
Property Value
Type Description
bool
Overrides
System.Text.Json.Serialization.JsonConverter<string>.HandleNull

Methods

| Edit this page View Source

Read(ref Utf8JsonReader, Type, JsonSerializerOptions)

Reads and converts the JSON to type string.

Declaration
public override string Read(ref Utf8JsonReader reader, Type typeToConvert, JsonSerializerOptions options)
Parameters
Type Name Description
Utf8JsonReader reader

The reader.

Type typeToConvert

The type to convert.

JsonSerializerOptions options

An object that specifies serialization options to use.

Returns
Type Description
string

The converted value.

Overrides
System.Text.Json.Serialization.JsonConverter<string>.Read(ref System.Text.Json.Utf8JsonReader, System.Type, System.Text.Json.JsonSerializerOptions)
| Edit this page View Source

Write(Utf8JsonWriter, string, JsonSerializerOptions)

Writes a specified value as JSON.

Declaration
public override void Write(Utf8JsonWriter writer, string value, JsonSerializerOptions options)
Parameters
Type Name Description
Utf8JsonWriter writer

The writer to write to.

string value

The value to convert to JSON.

JsonSerializerOptions options

An object that specifies serialization options to use.

Overrides
System.Text.Json.Serialization.JsonConverter<string>.Write(System.Text.Json.Utf8JsonWriter, string, System.Text.Json.JsonSerializerOptions)
  • Edit this page
  • View Source
In this article
Back to top Generated by DocFX