Options
All
  • Public
  • Public/Protected
  • All
Menu

Class TimeSpan

Hierarchy

  • TimeSpan

Implements

  • Duration

Index

Constructors

constructor

  • Parameters

    • args: any

    Returns TimeSpan

Properties

Private duration

duration: Duration

Static Private MaxMilliSeconds

MaxMilliSeconds: number

Static Private MaxSeconds

MaxSeconds: number

Static MaxValueTimeSpan

MaxValueTimeSpan: TimeSpan

Static Private MillisPerDay

MillisPerDay: number

Static Private MillisPerHour

MillisPerHour: number

Static Private MillisPerMinute

MillisPerMinute: number

Static Private MillisPerSecond

MillisPerSecond: number

Static Private MinMilliSeconds

MinMilliSeconds: number

Static Private MinSeconds

MinSeconds: number

Static MinValueTimeSpan

MinValueTimeSpan: TimeSpan

Static Zero

Zero: TimeSpan

Accessors

TotalDays

  • get TotalDays(): number
  • Returns number

TotalHours

  • get TotalHours(): number
  • Returns number

TotalMilliseconds

  • get TotalMilliseconds(): number
  • Returns number

TotalMinutes

  • get TotalMinutes(): number
  • Returns number

TotalMonths

  • get TotalMonths(): number
  • Returns number

TotalSeconds

  • get TotalSeconds(): number
  • Returns number

TotalYears

  • get TotalYears(): number
  • Returns number

Methods

add

  • Parameters

    • n: number
    • p: string

    Returns TimeSpan

  • Parameters

    • n: number

    Returns TimeSpan

  • Parameters

    Returns TimeSpan

as

  • as(units: string): number
  • Parameters

    • units: string

    Returns number

asDays

  • asDays(): number
  • Returns number

asHours

  • asHours(): number
  • Returns number

asMilliseconds

  • asMilliseconds(): number
  • Returns number

asMinutes

  • asMinutes(): number
  • Returns number

asMonths

  • asMonths(): number
  • Returns number

asSeconds

  • asSeconds(): number
  • Returns number

asYears

  • asYears(): number
  • Returns number

days

  • days(): number
  • Returns number

hours

  • hours(): number
  • Returns number

humanize

  • humanize(withSuffix?: boolean): string
  • Parameters

    • Optional withSuffix: boolean

    Returns string

milliseconds

  • milliseconds(): number
  • Returns number

minutes

  • minutes(): number
  • Returns number

months

  • months(): number
  • Returns number

seconds

  • seconds(): number
  • Returns number

subtract

  • Parameters

    • n: number
    • p: string

    Returns TimeSpan

  • Parameters

    • n: number

    Returns TimeSpan

  • Parameters

    Returns TimeSpan

toISOString

  • toISOString(): string
  • Returns string

years

  • years(): number
  • Returns number

Static FromDays

  • Parameters

    • value: number

    Returns TimeSpan

Static FromHours

  • Parameters

    • value: number

    Returns TimeSpan

Static FromMilliseconds

  • FromMilliseconds(value: number): TimeSpan
  • Parameters

    • value: number

    Returns TimeSpan

Static FromMinutes

  • Parameters

    • value: number

    Returns TimeSpan

Static FromSeconds

  • Parameters

    • value: number

    Returns TimeSpan

Generated using TypeDoc