scala

class BigDecimal

[source: scala/BigDecimal.scala]

@serializable

class BigDecimal(val bigDecimal : java.math.BigDecimal)
extends java.lang.Number with AnyRef
Author
Stephane Micheloud
Version
1.0
Method Summary
def % (that : BigDecimal) : BigDecimal
Remainder of BigDecimals
def * (that : BigDecimal) : BigDecimal
Multiplication of BigDecimals
def + (that : BigDecimal) : BigDecimal
Addition of BigDecimals
def - (that : BigDecimal) : BigDecimal
Subtraction of BigDecimals
def / (that : BigDecimal) : BigDecimal
Division of BigDecimals
def /% (that : BigDecimal) : (BigDecimal, BigDecimal)
Returns a pair of two BigDecimals containing (this / that) and (this % that).
def < (that : BigDecimal) : Boolean
Less-than of BigDecimals
def <= (that : BigDecimal) : Boolean
Less-than-or-equals comparison of BigDecimals
def > (that : BigDecimal) : Boolean
Greater-than comparison of BigDecimals
def >= (that : BigDecimal) : Boolean
Greater-than-or-equals comparison of BigDecimals
def abs : BigDecimal
Returns the absolute value of this BigDecimal
override def byteValue : Byte
Converts this BigDecimal to a byte. If the BigDecimal is too big to fit in a byte, only the low-order 8 bits are returned. Note that this conversion can lose information about the overall magnitude of the BigDecimal value as well as return a result with the opposite sign.
def charValue : Char
Converts this BigDecimal to a char. If the BigDecimal is too big to fit in a char, only the low-order 16 bits are returned. Note that this conversion can lose information about the overall magnitude of the BigDecimal value and that it always returns a positive result.
def compare (that : BigDecimal) : Int
Compares this BigDecimal with the specified BigDecimal
def doubleValue : Double
Converts this BigDecimal to a Double. if this BigDecimal has too great a magnitude to represent as a float, it will be converted to Float.NEGATIVE_INFINITY or Float.POSITIVE_INFINITY as appropriate.
override def equals (that : Any) : Boolean
Compares this BigDecimal with the specified value for equality.
def equals (that : BigDecimal) : Boolean
Compares this BigDecimal with the specified BigDecimal for equality.
def floatValue : Float
Converts this BigDecimal to a float. if this BigDecimal has too great a magnitude to represent as a float, it will be converted to Float.NEGATIVE_INFINITY or Float.POSITIVE_INFINITY as appropriate.
override def hashCode : Int
Returns the hash code for this BigDecimal.
def intValue : Int
Converts this BigDecimal to an int. If the BigDecimal is too big to fit in a char, only the low-order 32 bits are returned. Note that this conversion can lose information about the overall magnitude of the BigDecimal value as well as return a result with the opposite sign.
def longValue : Long
Converts this BigDecimal to a Long. If the BigDecimal is too big to fit in a char, only the low-order 64 bits are returned. Note that this conversion can lose information about the overall magnitude of the BigDecimal value as well as return a result with the opposite sign.
def max (that : BigDecimal) : BigDecimal
Returns the maximum of this and that
def min (that : BigDecimal) : BigDecimal
Returns the minimum of this and that
def pow (exp : Int) : BigDecimal
Returns a BigDecimal whose value is (this raised to the power of exp).
override def shortValue : Short
Converts this BigDecimal to a short. If the BigDecimal is too big to fit in a byte, only the low-order 16 bits are returned. Note that this conversion can lose information about the overall magnitude of the BigDecimal value as well as return a result with the opposite sign.
def signum : Int
Returns the sign of this BigDecimal, i.e. -1 if it is less than 0, +1 if it is greater than 0 0 if it is equal to 0
def toPlainString : java.lang.String
Returns a string representation of this BigDecimal without an exponent field.
override def toString : java.lang.String
Returns the decimal String representation of this BigDecimal.
def unary_- : BigDecimal
Returns a BigDecimal whose value is the negation of this BigDecimal
Methods inherited from AnyRef
getClass, clone, notify, notifyAll, wait, wait, wait, finalize, ==, !=, eq, ne, synchronized
Methods inherited from Any
==, !=, isInstanceOf, asInstanceOf
Method Details
override def hashCode : Int
Returns the hash code for this BigDecimal.

override def equals(that : Any) : Boolean
Compares this BigDecimal with the specified value for equality.

def equals(that : BigDecimal) : Boolean
Compares this BigDecimal with the specified BigDecimal for equality.

def compare(that : BigDecimal) : Int
Compares this BigDecimal with the specified BigDecimal

def <=(that : BigDecimal) : Boolean
Less-than-or-equals comparison of BigDecimals

def >=(that : BigDecimal) : Boolean
Greater-than-or-equals comparison of BigDecimals

def <(that : BigDecimal) : Boolean
Less-than of BigDecimals

def >(that : BigDecimal) : Boolean
Greater-than comparison of BigDecimals

def +(that : BigDecimal) : BigDecimal
Addition of BigDecimals

def -(that : BigDecimal) : BigDecimal
Subtraction of BigDecimals

def *(that : BigDecimal) : BigDecimal
Multiplication of BigDecimals

def /(that : BigDecimal) : BigDecimal
Division of BigDecimals

def %(that : BigDecimal) : BigDecimal
Remainder of BigDecimals

def /%(that : BigDecimal) : (BigDecimal, BigDecimal)
Returns a pair of two BigDecimals containing (this / that) and (this % that).

def min(that : BigDecimal) : BigDecimal
Returns the minimum of this and that

def max(that : BigDecimal) : BigDecimal
Returns the maximum of this and that

def pow(exp : Int) : BigDecimal
Returns a BigDecimal whose value is (this raised to the power of exp).

def unary_- : BigDecimal
Returns a BigDecimal whose value is the negation of this BigDecimal

def abs : BigDecimal
Returns the absolute value of this BigDecimal

def signum : Int
Returns the sign of this BigDecimal, i.e. -1 if it is less than 0, +1 if it is greater than 0 0 if it is equal to 0

override def byteValue : Byte
Converts this BigDecimal to a byte. If the BigDecimal is too big to fit in a byte, only the low-order 8 bits are returned. Note that this conversion can lose information about the overall magnitude of the BigDecimal value as well as return a result with the opposite sign.
Overrides
java.lang.Number.java.lang.Number.byteValue

override def shortValue : Short
Converts this BigDecimal to a short. If the BigDecimal is too big to fit in a byte, only the low-order 16 bits are returned. Note that this conversion can lose information about the overall magnitude of the BigDecimal value as well as return a result with the opposite sign.
Overrides
java.lang.Number.java.lang.Number.shortValue

def charValue : Char
Converts this BigDecimal to a char. If the BigDecimal is too big to fit in a char, only the low-order 16 bits are returned. Note that this conversion can lose information about the overall magnitude of the BigDecimal value and that it always returns a positive result.

def intValue : Int
Converts this BigDecimal to an int. If the BigDecimal is too big to fit in a char, only the low-order 32 bits are returned. Note that this conversion can lose information about the overall magnitude of the BigDecimal value as well as return a result with the opposite sign.
Overrides
java.lang.Number.java.lang.Number.intValue

def longValue : Long
Converts this BigDecimal to a Long. If the BigDecimal is too big to fit in a char, only the low-order 64 bits are returned. Note that this conversion can lose information about the overall magnitude of the BigDecimal value as well as return a result with the opposite sign.
Overrides
java.lang.Number.java.lang.Number.longValue

def floatValue : Float
Converts this BigDecimal to a float. if this BigDecimal has too great a magnitude to represent as a float, it will be converted to Float.NEGATIVE_INFINITY or Float.POSITIVE_INFINITY as appropriate.
Overrides
java.lang.Number.java.lang.Number.floatValue

def doubleValue : Double
Converts this BigDecimal to a Double. if this BigDecimal has too great a magnitude to represent as a float, it will be converted to Float.NEGATIVE_INFINITY or Float.POSITIVE_INFINITY as appropriate.
Overrides
java.lang.Number.java.lang.Number.doubleValue

override def toString : java.lang.String
Returns the decimal String representation of this BigDecimal.

def toPlainString : java.lang.String
Returns a string representation of this BigDecimal without an exponent field.