native_methods/duration_methods library

Classes

Abs
Returns the absolute value of the duration.
CompareTo
Compares the duration to another duration and returns the result of the comparison. Returns 0 if the durations are equal, a negative number if the duration is less than the other duration, and a positive number if the duration is greater than the other duration.
InHours
Returns the number of hours in the duration.
InMilliseconds
Returns the number of milliseconds in the duration.
InMinutes
Returns the number of minutes in the duration.
InSeconds
Returns the number of seconds in the duration.
InYears
Returns the number of years in the duration.
IsNegative
Returns true if the duration is negative.

Functions

registerDurationExtensions() → void
Registers native methods for the Duration type. These are registere automatically by the VM.