The state restoration configuration options.

T - The type of object held by the restorable collection.

interface IOptions<T extends IObservableDisposable> {
    args?: (obj: T) => ReadonlyPartialJSONObject;
    command: string;
    name: (obj: T) => string;
    when?: Promise<any> | Promise<any>[];
}

Type Parameters

Hierarchy (View Summary)

Properties

Properties

args?: (obj: T) => ReadonlyPartialJSONObject

A function that returns the args needed to restore an instance.

command: string

The command to execute when restoring instances.

name: (obj: T) => string

A function that returns a unique persistent name for this instance.

when?: Promise<any> | Promise<any>[]

The point after which it is safe to restore state.