NumExtensions extension

on

Properties

area double

Available on num, provided by the NumExtensions extension

Returns the area of a circle with this number as radius.
no setter
cubeVolume double

Available on num, provided by the NumExtensions extension

Returns the cube volume with this number as radius.
no setter
day Duration

Available on num, provided by the NumExtensions extension

Converts this number to a Duration in days.
no setter
fixed0 String

Available on num, provided by the NumExtensions extension

Returns a string representation of this number with 1 decimal place.
no setter
fixed00 String

Available on num, provided by the NumExtensions extension

Returns a string representation of this number with 2 decimal places.
no setter
h double

Available on num, provided by the NumExtensions extension

Dynamic height helper to support various screen sizes.
no setter
half double

Available on num, provided by the NumExtensions extension

Returns half of this number as double.
no setter
horizontalSpace SizedBox

Available on num, provided by the NumExtensions extension

Returns a SizedBox widget with the width set to this number.
no setter
hr Duration

Available on num, provided by the NumExtensions extension

Converts this number to a Duration in hours.
no setter
isEven bool

Available on num, provided by the NumExtensions extension

Returns true if this number is a even number.
no setter
min Duration

Available on num, provided by the NumExtensions extension

Converts this number to a Duration in minutes.
no setter
misec Duration

Available on num, provided by the NumExtensions extension

Converts this number to a Duration in microseconds.
no setter
msec Duration

Available on num, provided by the NumExtensions extension

Converts this number to a Duration in milliseconds.
no setter
perimeter double

Available on num, provided by the NumExtensions extension

Returns the perimeter of a circle with this number as radius.
no setter
quarter double

Available on num, provided by the NumExtensions extension

Returns one quarter (25%) of this number as double.
no setter
screenHeight double

Available on num, provided by the NumExtensions extension

Get the logical screen height multiplied by this number.
no setter
screenWidth double

Available on num, provided by the NumExtensions extension

Get the logical screen width multiplied by this number.
no setter
sec Duration

Available on num, provided by the NumExtensions extension

Converts this number to a Duration in seconds.
no setter
sphere double

Available on num, provided by the NumExtensions extension

Returns the surface area of a sphere with this number as radius.
no setter
sqRoot double

Available on num, provided by the NumExtensions extension

Returns the square root (√) of this number.
no setter
square double

Available on num, provided by the NumExtensions extension

Returns the square of this number as double (n * n).
no setter
toColor Color

Available on num, provided by the NumExtensions extension

Converts this number to a Color with the alpha channel set to this number.
no setter
verticalSpace SizedBox

Available on num, provided by the NumExtensions extension

Returns a SizedBox widget with the height set to this number.
no setter
w double

Available on num, provided by the NumExtensions extension

Dynamic width helper to support various screen sizes.
no setter

Methods

format(String formatStr) String

Available on num, provided by the NumExtensions extension

Returns a string representation of this number with the format provided as a parameter.
isBetween(num min, num max) bool

Available on num, provided by the NumExtensions extension

Returns true if this number is between the provided min and max values.
isDivisibleBy(int divisor) bool

Available on num, provided by the NumExtensions extension

Returns true if this number is divisible by the provided divisor.