@vivliostyle/core
    Preparing search index...

    Class Task

    An asynchronous, time-sliced task.

    Index

    Constructors

    Properties

    callbacks: (() => void)[] = []
    continuation: Continuation<any> = null
    exception: Error = null
    name: string
    result: any = null
    running: boolean = true
    scheduler: Scheduler
    top: Frame<any> = null
    waitTarget: string = null

    Methods

    • Fill the stack trace in the exception

      Parameters

      • err: Error

        exception

      Returns void

    • Returns string

      task name.

    • Parameters

      • err: Error

        exception to throw in the task's context.

      Returns void

    • Returns boolean

      true if task is still running.

    • Parameters

      • err: Error
      • Optionalopt_frame: Frame<any>

      Returns void

    • Unwind the stack. We have two stacks: async (maintained by frame parent link) and sync (regular JavaScript stack).

      Returns void

    • Register a callback to be called when the task is done. Callback is not executed in any task context. Multiple callbacks can be registered and they will be called in the registration order.

      Parameters

      • callback: () => void

      Returns void