Table of Contents

Interface IRecordLinkResolver<T>

Namespace
Chronicler
Assembly
Chronicler.dll

Maps host-owned link values to stable IDs and resolves those IDs during loading.

public interface IRecordLinkResolver<T>

Type Parameters

T

The declared link type for which the resolver is registered.

Remarks

Use IDs that identify corresponding values across save and load sessions. A false result allows ChronicleLinkRegistry to consult instance registrations.

Methods

TryGetReferenceId(T, out string?)

Looks up an ID for a value in the current session.

bool TryGetReferenceId(T value, out string? id)

Parameters

value T

The host-owned value to identify.

id string

A non-null stable ID on success. The registry ignores this output on failure.

Returns

bool

true if the resolver supplied an ID.

TryResolveReference(string, out T)

Looks up a recorded ID in the destination session.

bool TryResolveReference(string id, out T value)

Parameters

id string

The stable ID read from the record.

value T

The destination value on success. The registry ignores this output on failure.

Returns

bool

true if the resolver supplied a value.