$Duration class

dart_eval bimodal wrapper for Duration

Implemented types

Constructors

$Duration.wrap(Duration $value)
Wrap a Duration in a $Duration

Properties

$reified Duration
Fully reify the underlying value so it can be used in a Dart context. For example, recursively transform collections into their underlying $values.
no setteroverride
$value Duration
The backing Dart value of this $Value
final
hashCode int
The hash code for this object.
no setterinherited
inDays int
The number of entire days spanned by this Duration.
no setteroverride
inHours int
The number of entire hours spanned by this Duration.
no setteroverride
inMicroseconds int
The number of whole microseconds spanned by this Duration.
no setteroverride
inMilliseconds int
The number of whole milliseconds spanned by this Duration.
no setteroverride
inMinutes int
The number of whole minutes spanned by this Duration.
no setteroverride
inSeconds int
The number of whole seconds spanned by this Duration.
no setteroverride
isNegative bool
Whether this Duration is negative.
no setteroverride
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

$getProperty(Runtime runtime, String identifier) $Value?
Get a property by identifier on this instance
override
$getRuntimeType(Runtime runtime) int
override
$setProperty(Runtime runtime, String identifier, $Value value) → void
Set a property by identifier on this instance to value
override
abs() Duration
Creates a new Duration representing the absolute length of this Duration.
override
compareTo(Duration other) int
Compares this Duration to other, returning zero if the values are equal.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator *(num factor) Duration
Multiplies this Duration by the given factor and returns the result as a new Duration object.
override
operator +(Duration other) Duration
Adds this Duration and other and returns the sum as a new Duration object.
override
operator -(Duration other) Duration
Subtracts other from this Duration and returns the difference as a new Duration object.
override
operator <(Duration other) bool
Whether this Duration is shorter than other.
override
operator <=(Duration other) bool
Whether this Duration is shorter than or equal to other.
override
operator ==(Object other) bool
The equality operator.
inherited
operator >(Duration other) bool
Whether this Duration is longer than other.
override
operator >=(Duration other) bool
Whether this Duration is longer than or equal to other.
override
operator unary-() Duration
Creates a new Duration with the opposite direction of this Duration.
override
operator ~/(int quotient) Duration
Divides this Duration by the given quotient and returns the truncated result as a new Duration object.
override

Static Methods

configureForRuntime(Runtime runtime) → void

Constants

$declaration → const BridgeClassDef
Compile-time class declaration for $Duration
$type → const BridgeTypeRef
Compile-time type definition for $Duration