BridgeFieldPath class

Namespace Runic.Application.Views.Generated in Runic.Application.Views 0.23.0

public sealed class BridgeFieldPath

One field path below a member or a row (field-paths/1). Created by generated bridges.

Parameters

path

The wire member names below the member or the row, such as ["street"].

set

Returns a copy of the object or row with the value at the path replaced by the decoded wire value, keeping every member the wire does not carry. It throws FormatException, JsonException, ArgumentException or OverflowException for a value that is not valid input.

Constructors

BridgeFieldPath

public BridgeFieldPath(string[] path, Func<object, JsonElement, object> set)

One field path below a member or a row (field-paths/1). Created by generated bridges.

Parameters

path

The wire member names below the member or the row, such as ["street"].

set

Returns a copy of the object or row with the value at the path replaced by the decoded wire value, keeping every member the wire does not carry. It throws FormatException, JsonException, ArgumentException or OverflowException for a value that is not valid input.

Properties

Path

public IReadOnlyList<string> Path { get; }

The wire member names below the member or the row.

Set

public Func<object, JsonElement, object> Set { get; }

Copies the object or row with the value at the path replaced.

Methods

ReplaceMember

public static JsonDocument ReplaceMember(Action<Utf8JsonWriter> writeObject, string member, Action<Utf8JsonWriter> writeValue)

The JSON object that writeObject writes, with its member member replaced by what writeValue writes: the copy of a sealed class whose settable members are all on the wire, for its generated codec to read back.