Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface Task

Task that can be added to the TaskQueue

Hierarchy

  • Task

Index

Properties

Optional estimatedProcessTime

estimatedProcessTime: undefined | (() => number)

An optional function that returns an estimated process time, this is not directly used by the TaskQueue but can be used by an Task Scheduler to schedule the processing

execute

execute: () => void

The Function that will be executed when the Task is processed

Type declaration

    • (): void
    • Returns void

getPriority

getPriority: () => number

A function to retrieve the priority of the Task, with 0 being the highest priority, and the first to be executed

Type declaration

    • (): number
    • Returns number

group

group: string

The group by which similar tasks in the TaskQueue are combined

Optional isExpired

isExpired: undefined | (() => boolean)

An optional function that defines if a Task is alread expired and therefore can be removed from the TaskQueue

Generated using TypeDoc