Options
All
  • Public
  • Public/Protected
  • All
Menu

This class provides a simple means for storing and calculating time quantities.

Hierarchy

Implements

Index

Constructors

constructor

  • Parameters

    • Default value _quantity: number = 0

    Returns TimeQuantity

Properties

Protected _quantity

_quantity: number

Protected _total

Accessors

direction

  • get direction(): number
  • +1, 0, or -1 depending on the time direction.

    Returns number

total

  • Returns an object with all units exposed as totals.

    Returns ITimeMeasurement

Methods

compareTo

  • Compares this instance against any other time quantity instance.

    Parameters

    Returns number

equals

  • Compares this instance against any other time quantity instance and return true if the amount of time is the same.

    Parameters

    Returns boolean

getTotal

  • Returns the total amount of time measured in the requested TimeUnit.

    Parameters

    Returns number

getTotalMilliseconds

  • getTotalMilliseconds(): number

Generated using TypeDoc