DurationExtension extension

Duration extensions for formatting

on

Properties

abs → Duration

Available on Duration, provided by the DurationExtension extension

Absolute value of duration
no setter
isNegative → bool

Available on Duration, provided by the DurationExtension extension

Check if duration is negative
no setter
isPositive → bool

Available on Duration, provided by the DurationExtension extension

Check if duration is positive
no setter
isZero → bool

Available on Duration, provided by the DurationExtension extension

Check if duration is zero
no setter
negate → Duration

Available on Duration, provided by the DurationExtension extension

Negate duration
no setter

Methods

toHumanString() → String

Available on Duration, provided by the DurationExtension extension

Format as human readable string
toMinutesSecondsString() → String

Available on Duration, provided by the DurationExtension extension

Format as MM:SS (for calls, videos, etc.)
toTimeString() → String

Available on Duration, provided by the DurationExtension extension

Format as HH:MM:SS