W-CF Documentation - v11.0.0
    Preparing search index...

    Class DelayedTask<T>

    A task which will be executed after a given delay.

    Type Parameters

    • T = void
    Index
    • Type Parameters

      • T = void

      Parameters

      • pTask: () => Promise<T>

      Returns DelayedTask<T>

    • Starts the execution of the task. The task will be executed only once if consecutive calls are made during the delay.

      Parameters

      • pDelay: number

        Delay in milliseconds before the task gets executed.

      • pRestartTimer: boolean = false

        If true and the delay timer is currently running, the timer will be restartet with the new delay. If false the currently running timer will stay active and the new delay is ignored. (default: false)

      Returns Promise<T>