Options
All
  • Public
  • Public/Protected
  • All
Menu

External module "timer"

Allows you to create, start, stop and react to timers.

Index

Functions

clearInterval

  • clearInterval(id: number): void
  • Clears repeated function which was set up by calling setInterval().

    Parameters

    • id: number

      The identifier returned by the setInterval() method.

    Returns void

clearTimeout

  • clearTimeout(id: number): void
  • Clears the delay set by a call to the setTimeout function.

    Parameters

    • id: number

      The identifier returned by the previously called setTimeout() method.

    Returns void

setInterval

  • setInterval(callback: Function, milliseconds?: number, ...args: any[]): number
  • Calls a function repeatedly with a delay between each call.

    Parameters

    • callback: Function

      The function to be called.

    • Optional milliseconds: number

      The delay between each function call.

    • Rest ...args: any[]

      One or more parameter to use once the function is called. Defaults to no parameters.

    Returns number

setTimeout

  • setTimeout(callback: Function, milliseconds?: number, ...args: any[]): number
  • Calls a function after a specified delay.

    Parameters

    • callback: Function

      The function to be called.

    • Optional milliseconds: number

      The time to wait before the function is called. Defaults to 0.

    • Rest ...args: any[]

      One or more parameter to use once the function is called. Defaults to no parameters.

    Returns number

Legend

  • Module
  • Object literal
  • Variable
  • Function
  • Function with type parameter
  • Index signature
  • Type alias
  • Enumeration
  • Enumeration member
  • Property
  • Method
  • Interface
  • Interface with type parameter
  • Constructor
  • Property
  • Method
  • Index signature
  • Class
  • Class with type parameter
  • Constructor
  • Property
  • Method
  • Accessor
  • Index signature
  • Inherited constructor
  • Inherited property
  • Inherited method
  • Inherited accessor
  • Protected property
  • Protected method
  • Protected accessor
  • Private property
  • Private method
  • Private accessor
  • Static property
  • Static method