BigDecimal class

Implemented types

Constructors

BigDecimal.fromBigInt(BigInt value)
factory
BigDecimal.parse(String value)
factory

Properties

hashCode int
The hash code for this object.
no setteroverride
intVal BigInt
final
precision int
latefinal
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
scale int
final

Methods

abs() BigDecimal
compareTo(BigDecimal other) int
Compares this object to another object.
override
divide(BigDecimal divisor, {RoundingMode roundingMode = RoundingMode.UNNECESSARY, int? scale}) BigDecimal
exactlyEquals(dynamic other) bool
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
pow(int n) BigDecimal
toBigInt({RoundingMode roundingMode = RoundingMode.UNNECESSARY}) BigInt
toDouble() double
toInt({RoundingMode roundingMode = RoundingMode.UNNECESSARY}) int
toPlainString() String
toString() String
A string representation of this object.
override
withScale(int newScale, {RoundingMode roundingMode = RoundingMode.UNNECESSARY}) BigDecimal

Operators

operator *(BigDecimal other) BigDecimal
operator +(BigDecimal other) BigDecimal
operator -(BigDecimal other) BigDecimal
operator <(BigDecimal other) bool
operator <=(BigDecimal other) bool
operator ==(dynamic other) bool
The equality operator.
override
operator >(BigDecimal other) bool
operator >=(BigDecimal other) bool
operator unary-() BigDecimal

Static Properties

one BigDecimal
getter/setter pair
two BigDecimal
getter/setter pair
zero BigDecimal
getter/setter pair

Static Methods

createAndStripZerosForScale(BigInt intVal, int scale, int preferredScale) BigDecimal
nextNonDigit(String value, [int start = 0]) int
sumScale(int scaleA, int scaleB) int
tryParse(String value) BigDecimal?