Represents the execution scope for a span, combining the trace instance and the active span. This interface is used as the context for executing functions within a span's scope.

3.4.0

interface ISpanScope<T> {
    host: T;
    prvSpan?: IReadableSpan;
    restore(): void;
    span: IReadableSpan;
}

Type Parameters

Properties

Methods

Properties

host: T

The trace host (core or AISKU instance).

3.4.0

prvSpan?: IReadableSpan

The previously active span before this scope was created, if any.

3.4.0

The active span for this execution scope.

3.4.0

Methods