tuil
ReferencePackages@mwillbanks/tuil-operationsAPI

OperationSnapshot

interface exported by @mwillbanks/tuil-operations.

View rawEdit

interface

Public interface exported by @mwillbanks/tuil-operations.

export interface OperationSnapshot<TResult = unknown> {
  readonly id: string;
  readonly title: string;
  readonly description?: string;
  readonly status: OperationStatus;
  readonly progress?: OperationProgress;
  readonly attempt: number;
  readonly startedAt?: number;
  readonly completedAt?: number;
  readonly result?: TResult;
  readonly error?: OperationError;
  readonly children: readonly OperationSnapshot[];
  readonly metadata: Readonly<Record<string, unknown>>;
  readonly logs: readonly string[];
}

Members

MemberTypeRequiredDescriptionRelated types
idstringYesThe id member uses the string contract.
titlestringYesThe title member uses the string contract.
descriptionstring | undefinedNoThe description member uses the string | undefined contract.
statusOperationStatusYesThe status member uses the OperationStatus contract.OperationStatus
progressOperationProgress | undefinedNoThe progress member uses the OperationProgress | undefined contract.OperationProgress
attemptnumberYesThe attempt member uses the number contract.
startedAtnumber | undefinedNoThe startedAt member uses the number | undefined contract.
completedAtnumber | undefinedNoThe completedAt member uses the number | undefined contract.
resultTResult | undefinedNoThe result member uses the TResult | undefined contract.
errorOperationError | undefinedNoThe error member uses the OperationError | undefined contract.OperationError
childrenreadonly OperationSnapshot<unknown>[]YesThe children member uses the readonly OperationSnapshot<unknown>[] contract.OperationSnapshot
metadataReadonly<Record<string, unknown>>YesThe metadata member uses the Readonly<Record<string, unknown>> contract.
logsreadonly string[]YesThe logs member uses the readonly string[] contract.

Parameters

This declaration has no public members.

Returns

This declaration does not return a value.

Throws

No thrown errors are documented for this declaration.

Source

View the secondary source reference

Package

@mwillbanks/tuil-operations

On this page