NumberUtils class

Utility functions for number processing

Constructors

NumberUtils()

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

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 ==(Object other) bool
The equality operator.
inherited

Static Methods

amountFormat(dynamic value, {int digit = 0}) String
Format number with thousand separators
formatDecimalPart(double number, int precision) int
Format decimal part according to required precision
isNegative(double number) bool
Check if number is negative
isPositive(double number) bool
Check if number is positive
isValidNumber(dynamic value) bool
Validate if the value is a valid number
isZero(double number) bool
Check if number is zero
replaceArabicNumber(String input) String
Replace Arabic/Hindi numerals with English numerals
splitNumber(double number) NumberParts
Split number into integer and decimal parts
toDouble(dynamic value) double?
Convert value to double