Duration
Represents an ISO 8601 duration. Contains both date-based values (years, months, days) and time-based values (seconds, nanoseconds).
Created Duration
objects are frozen with Object.freeze()
in constructor and thus immutable.
Constructor Summary
Public Constructor | ||
public |
constructor(months: NumberOrInteger, days: NumberOrInteger, seconds: NumberOrInteger, nanoseconds: NumberOrInteger) |
Member Summary
Public Members | ||
public |
days: NumberOrInteger The number of days. |
|
public |
months: NumberOrInteger The number of months. |
|
public |
nanoseconds: NumberOrInteger The number of nanoseconds. |
|
public |
seconds: NumberOrInteger The number of seconds. |
Public Constructors
public constructor(months: NumberOrInteger, days: NumberOrInteger, seconds: NumberOrInteger, nanoseconds: NumberOrInteger) source
Params:
Name | Type | Attribute | Description |
months | NumberOrInteger | The number of months for the new duration. |
|
days | NumberOrInteger | The number of days for the new duration. |
|
seconds | NumberOrInteger | The number of seconds for the new duration. |
|
nanoseconds | NumberOrInteger | The number of nanoseconds for the new duration. |