Class Rate

Hierarchy

  • Rate

Constructors

  • Parameters

    • periodMs: number = minuteMs

      the length of time to retain event timestamps for computing rate. Events older than this value will be discarded.

    • warmupMs: number = secondMs

      return null from #msPerEvent if it's been less than warmupMs since construction or #clear.

    Returns Rate

Properties

periodMs: number = minuteMs
warmupMs: number = secondMs

Accessors

  • get eventCount(): number
  • Returns number

  • get eventsPerMinute(): number
  • Returns number

  • get eventsPerMs(): number
  • Returns number

  • get eventsPerSecond(): number
  • Returns number

  • get msPerEvent(): null | number
  • Returns null | number

  • get msSinceLastEvent(): null | number
  • Returns null | number

Methods

  • Returns void

Generated using TypeDoc