Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Oracle Application Development Framework Business Components Domains Java API Reference 10g Release 3 (10.1.3) B16006-01
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## oracle.jbo.domain
Class Number

`java.lang.Object
oracle.sql.Datum
oracle.sql.NUMBER
oracle.jbo.domain.Number`

All Implemented Interfaces:
  oracle.sql.CustomDatum, oracle.jbo.domain.DomainInterface, oracle.jbo.domain.KeyAttributeInterface, oracle.jdbc.internal.ObjectData, java.io.Serializable

public class Number
extends oracle.sql.NUMBER
implements oracle.jbo.domain.DomainInterface, oracle.jbo.domain.KeyAttributeInterface, oracle.sql.CustomDatum, java.io.Serializable

This class extends `oracle.sql.NUMBER`, Oracle's Java representation of the NUMBER database type. This class allows an instance of the `oracle.sql.NUMBER` to be used as a domain object. The intent of many of the methods in this class is to wrap the corresponding method in the `oracle.sql.NUMBER` class such that it returns an instance of an `oracle.jbo.domain.Number` object.

The `oracle.jbo.domain.Number` domain class is the Java representation of the underlying database type that you must use if you want to exploit the domain feature of Business Components for Java.

Since:
  JDeveloper 3.0
See Also:
  Serialized Form

Constructor Summary
`Number()` Creates a `Number` Domain object representing zero.
`Number(java.math.BigDecimal value)` Creates a `Number` Domain object from a `BigDecimal`.
`Number(java.math.BigInteger value)` Creates a `Number` Domain object from a `BigInteger`.
`Number(boolean value)` Creates a `Number` Domain object from a `Boolean`.
`Number(byte value)` Creates a `Number` Domain object from a `byte`.
`Number(byte[] value)` Internal: Applications should not invoke this method.
`Number(double value)` Creates a `Number` Domain object from an `double`.
`Number(java.lang.Double value)` Creates a `Number` Domain object from an `Double` object.
`Number(float value)` Creates a `Number` Domain object from an `float`.
`Number(int value)` Creates a `Number` Domain object from an `int`.
`Number(long value)` Creates a `Number` Domain object from an `long`.
`Number(java.lang.Long value)` Creates a `Number` Domain object from an `Long` object.
`Number(Number value)` Creates a `Number` identical to an existing `Number`.
`Number(oracle.sql.NUMBER value)` Creates a `Number` Domain object from an SQL `NUMBER`.
`Number(java.lang.Object value)` Creates a `Number` Domain object from an arbitrary `Object`.
`Number(short value)` Creates a `Number` Domain object from an `short`.
`Number(java.lang.String value)` Creates a `Number` Domain object from a Java `String`.
`Number(java.lang.String value, int precision)` Creates a `Number` Domain object from a Java `String`.

Method Summary
`oracle.sql.NUMBER` | `abs()` Finds the absolute value of `this`.
`oracle.sql.NUMBER` | `acos()` Calculates the arc cosine of `this`.
`Number` | `add(double n)` Adds another number to `this`.
`Number` | `add(int n)` Adds another number to `this`.
`Number` | `add(Number n)` Adds another number to `this`.
`oracle.sql.NUMBER` | `add(oracle.sql.NUMBER n)` Adds another number to `this`.
`oracle.sql.NUMBER` | `asin()` Calculates the arc sine of `this`.
`oracle.sql.NUMBER` | `atan()` Calculates the arc tangent of `this`.
`Number` | `atan2(Number x)` Calculates `atan(this, x)`.
`oracle.sql.NUMBER` | `atan2(oracle.sql.NUMBER x)` Calculates `atan(this, x)`.
`java.math.BigDecimal` | `bigDecimalValue()` Calls NUMBER.bigDecimalValue() to convert internal Oracle Number into a Java BigDecimal.
`java.math.BigInteger` | `bigIntegerValue()` Calls NUMBER.bigIntegerValue() to convert internal Oracle Number to a Java BigInteger.
`byte` | `byteValue()` Calls NUMBER.byteValue() to convert internal Oracle Number to a Java byte.
`oracle.sql.NUMBER` | `ceil()` Finds the ceiling of `this`.
`int` | `compareTo(double n)` Returns -1 if NUMBER is less than n, 0 if NUMBER and n are equal (==), 1 if NUMBER is greater than n.
`int` | `compareTo(int n)` Returns -1 if NUMBER is less than n, 0 if NUMBER and n are equal (==), 1 if NUMBER is greater than n.
`oracle.sql.NUMBER` | `cos()` Calculates the cosine of `this`.
`oracle.sql.NUMBER` | `cosh()` Calculates the hyperbolic cosine of `this`.
`oracle.sql.NUMBER` | `decrement()` Subtracts `1` from `this`.
`oracle.sql.NUMBER` | `div(oracle.sql.NUMBER n)` Divides `this` by another number.
`Number` | `divide(double n)` Divides `this` by another number.
`Number` | `divide(int n)` Divides `this` by another number.
`Number` | `divide(Number n)` Divides `this` by another number.
`oracle.sql.NUMBER` | `divide(oracle.sql.NUMBER n)` Divides `this` by another number.
`boolean` | `equals(java.lang.Object other)` Tests `this` for equality with another object.
`oracle.sql.NUMBER` | `exp()` Raises `e` to the power of `this`.
`oracle.sql.NUMBER` | `floatingPointRound(int precision)` Rounds `this` to a specified precision.
`oracle.sql.NUMBER` | `floor()` Finds the floor of `this`.
`static oracle.sql.NUMBER` | `formattedTextToNumber(java.lang.String num, java.lang.String fmt, java.lang.String lang)` Interprets a string as a number.
`java.math.BigDecimal` | `getBigDecimalValue()` Return a this domain's value as BigDecimal This method may be used to access the value for this domain in EL-expressions.
`static oracle.sql.CustomDatumFactory` | `getCustomDatumFactory()` Internal: Applications should not invoke this method.
`java.lang.Object` | `getData()` Internal: Applications should not invoke this method. Converts `this` to a JDBC object.
`double` | `getValue()` Return a this domain's value as double This method may be used to access the value for this domain in EL-expressions.
`int` | `hashCode()` Computes the hash code.
`oracle.sql.NUMBER` | `increment()` Adds `1` to `this`.
`int` | `intValue()` Calls NUMBER.intValue() to convert internal Oracle Number to a Java int.
`oracle.sql.NUMBER` | `ln()` Calculates the natural logarithm of `this`.
`Number` | `log(double base)` Calculates the log of `this` to the specified `base`.
`Number` | `log(int base)` Calculates the log of `this` to the specified `base`.
`Number` | `log(Number base)` Calculates the log of `this` to the specified `base`.
`oracle.sql.NUMBER` | `log(oracle.sql.NUMBER base)` Calculates the log of `this` to the specified `base`.
`long` | `longValue()` Calls NUMBER.longValue() to convert internal Oracle Number to a Java long.
`static void` | `main(java.lang.String[] argv)` Internal: Applications should not invoke this method.
`Number` | `mod(double n)` Calculates the remainder of `this/n`.
`Number` | `mod(int n)` Calculates the remainder of `this/n`.
`Number` | `mod(Number n)` Calculates the remainder of `this/n`.
`oracle.sql.NUMBER` | `mod(oracle.sql.NUMBER n)` Calculates the remainder of `this/n`.
`oracle.sql.NUMBER` | `mul(oracle.sql.NUMBER n)` Multiplies `this` by another number.
`Number` | `multiply(double n)` Multiplies `this` by another number.
`Number` | `multiply(int n)` Multiplies `this` by another number.
`Number` | `multiply(Number n)` Multiplies `this` by another number.
`oracle.sql.NUMBER` | `multiply(oracle.sql.NUMBER n)` Multiplies `this` by another number.
`oracle.sql.NUMBER` | `negate()` Calculates `0 - this`.
`oracle.sql.NUMBER` | `pow(int exp)` Raises `this` to the power of `exp`.
`Number` | `pow(Number exp)` Raises `this` to the power of `exp`.
`oracle.sql.NUMBER` | `pow(oracle.sql.NUMBER exp)` Raises `this` to the power of `exp`.
`oracle.sql.NUMBER` | `round(int decimal_place)` Rounds `this` to a specified precision.
`oracle.sql.NUMBER` | `scale(int left, int right, boolean[] big)` Rounds `this` to a specified precision, and tests for excessive magnitude.
`void` | `setContext(oracle.jbo.domain.DomainOwnerInterface owner, oracle.jbo.Transaction trans, java.lang.Object ctx)` Internal: Applications should not invoke this method.
`oracle.sql.NUMBER` | `shift(int digits)` Shift `this` a specified number of decimal places.
`short` | `shortValue()` Calls NUMBER.shortValue() to convert internal Oracle Number to a Java short.
`oracle.sql.NUMBER` | `sin()` Calculates the sine of `this`.
`oracle.sql.NUMBER` | `sinh()` Calculates the hyperbolic sine of `this`.
`oracle.sql.NUMBER` | `sqroot()` Calculates the square root of `this`.
`oracle.sql.NUMBER` | `sub(oracle.sql.NUMBER n)` Subtracts another number from `this`.
`Number` | `subtract(double n)` Subtracts another number from `this`.
`Number` | `subtract(int n)` Subtracts another number from `this`.
`Number` | `subtract(Number n)` Subtracts another number from `this`.
`oracle.sql.NUMBER` | `subtract(oracle.sql.NUMBER n)` Subtracts another number from `this`.
`oracle.sql.NUMBER` | `tan()` Calculates the tangent of `this`.
`oracle.sql.NUMBER` | `tanh()` Calculates the hyperbolic tangent of `this`.
`static oracle.sql.NUMBER` | `textToPrecisionNumber(java.lang.String num, boolean precflag, int preclen, boolean scaleflag, int scalelen, java.lang.String lang)` Converts a string to a number with specified precision.
`oracle.sql.Datum` | `toDatum(oracle.jdbc.driver.OracleConnection conn)` Internal: Applications should not invoke this method.
`java.lang.String` | `toString()` For testing purposes only: converts `this` to a fixed-point number presented as a string.
`oracle.sql.NUMBER` | `truncate(int decimal_place)` Truncates `this`.

Methods inherited from class oracle.sql.NUMBER
`booleanValue, compareTo, doubleValue, e, floatValue, isConvertibleTo, isInf, isInt, isNegInf, isPosInf, isValid, isZero, ln10, makeJdbcArray, negInf, pi, posInf, sign, stringValue, toBigDecimal, toBigInteger, toBoolean, toByte, toBytes, toBytes, toBytes, toBytes, toBytes, toBytes, toBytes, toBytes, toBytes, toBytes, toBytes, toDouble, toFloat, toFormattedText, toInt, toJdbc, toLong, toShort, toString, toText, zero`

Methods inherited from class oracle.sql.Datum
`asciiStreamValue, binaryStreamValue, characterStreamValue, compareBytes, dateValue, getBytes, getLength, getStream, setBytes, setShareBytes, shareBytes, timestampValue, timeValue`

Methods inherited from class java.lang.Object
`clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

Methods inherited from interface oracle.jbo.domain.KeyAttributeInterface
`getBytes, setBytes`

Constructor Detail

### Number

    public Number()

  Creates a `Number` Domain object representing zero. Use one of the `NullValue()` constructors to create a null `Number` object.

### Number

    public Number(byte[] value)

  Internal: Applications should not invoke this method.

  Creates a `Number` Domain object from the given byte array.

Parameters:
  `value` - a value returned by a previous call to `getBytes()` on an SQL object compatable with `Number`.

### Number

    public Number(byte value)

  Creates a `Number` Domain object from a `byte`.
Parameters:
  `value` - an 8-bit signed integer.

### Number

    public Number(int value)

  Creates a `Number` Domain object from an `int`.
Parameters:
  `value` - a 32-bit signed integer.

### Number

    public Number(java.lang.Long value)

  Creates a `Number` Domain object from an `Long` object.
Parameters:
  `value` - a 32-bit floating-point value.

### Number

    public Number(long value)

  Creates a `Number` Domain object from an `long`.
Parameters:
  `value` - a 64-bit signed integer.

### Number

    public Number(short value)

  Creates a `Number` Domain object from an `short`.
Parameters:
  `value` - a 16-bit signed integer.

### Number

    public Number(float value)

  Creates a `Number` Domain object from an `float`.
Parameters:
  `value` - a 32-bit floating-point value.

### Number

    public Number(double value)
           throws java.sql.SQLException

  Creates a `Number` Domain object from an `double`.
Parameters:
  `value` - a 64-bit floating-point value.
Throws:
  ``SQLException`` - on over/underflow of the exponent or on overflow of the mantissa.
  `java.sql.SQLException`

### Number

    public Number(java.lang.Double value)
           throws java.sql.SQLException

  Creates a `Number` Domain object from an `Double` object.
Parameters:
  `value` - a 64-bit floating-point value.
Throws:
  ``SQLException`` - on over/underflow of the exponent or on overflow of the mantissa.
  `java.sql.SQLException`

### Number

    public Number(java.math.BigDecimal value)
           throws java.sql.SQLException

  Creates a `Number` Domain object from a `BigDecimal`.

  Limitations:

  - This method may not preserve the scaling of the argument.
  - A `BigDecimal` distinguishes between 0 and -0. This information will be lost in the conversion.
  - At present, this method does not round. If the argument's mantissa has two many digits an exception is thrown.
Parameters:
  `value` - an arbitrarily precise floating-point value.
Throws:
  ``SQLException`` - on over/underflow of the exponent or on overflow of the mantissa.
  `java.sql.SQLException`

### Number

    public Number(java.math.BigInteger value)
           throws java.sql.SQLException

  Creates a `Number` Domain object from a `BigInteger`.
Parameters:
  `value` - an arbitrarily integer.
Throws:
  ``SQLException`` - on overflow.
  `java.sql.SQLException`

### Number

    public Number(java.lang.String value,
                  int precision)
           throws java.sql.SQLException

  Creates a `Number` Domain object from a Java `String`.
Parameters:
  `value` - a textual representation of a fixed-point number.
  `precision` - the maximum length of the string.
Throws:
  ``SQLException`` - on overflow.
  ``NumberFormatException`` - if value does not represent a valid `BigDecimal` value.
  `java.sql.SQLException`

### Number

    public Number(java.lang.String value)
           throws java.sql.SQLException

  Creates a `Number` Domain object from a Java `String`.
Parameters:
  `value` - a textual representation of a `BigDecimal`.
Throws:
  ``SQLException`` - on over/underflow of the exponent
  ``NumberFormatException`` - if value does not represent a valid `BigDecimal` value.
  `java.sql.SQLException`

### Number

    public Number(boolean value)

  Creates a `Number` Domain object from a `Boolean`.
Parameters:
  `value` - `true` or `false`. The instance is `0` if `value` is `false`, or `1` otherwise.

### Number

    public Number(java.lang.Object value)
           throws java.sql.SQLException

  Creates a `Number` Domain object from an arbitrary `Object`. One of the other constructors for `Number` is invoked, depending on the type of the argument.
Parameters:
  `value` - an arbitrary object.
Throws:
  ``SQLException`` - if the called method fails, or if the argument's type is not recognized.
  ``NumberFormatException`` - if value does not represent a valid `BigDecimal` value.
  `java.sql.SQLException`

### Number

    public Number(Number value)

  Creates a `Number` identical to an existing `Number`.
Parameters:
  `value` - a `Number` Domain object.
Throws:
  ``SQLException`` - never.

### Number

    public Number(oracle.sql.NUMBER value)

  Creates a `Number` Domain object from an SQL `NUMBER`.
Parameters:
  `value` - a `NUMBER` SQL object.
Throws:
  ``SQLException`` - never.

Method Detail

### getCustomDatumFactory

    public static oracle.sql.CustomDatumFactory getCustomDatumFactory()

  Internal: Applications should not invoke this method.

  Initializes the `Number` Domain. This method is invoked when JBO is initialized.

  Returns:
    the `CustomDatumFactory` for the `Number` Domain.

### toDatum

    public oracle.sql.Datum toDatum(oracle.jdbc.driver.OracleConnection conn)
                             throws java.sql.SQLException

  Internal: Applications should not invoke this method.

  Converts this `Number` Domain object back into an SQL `NUMBER` object.

  Specified by:
    `toDatum` in interface `oracle.sql.CustomDatum`
  Parameters:
    `conn` - `OracleConnection` Not used.
  Returns:
    A `Datum` containing `NUMBER` object.
  Throws:
    ``SQLException`` - Never.
    `java.sql.SQLException`

### getBigDecimalValue

    public java.math.BigDecimal getBigDecimalValue()

  Return a this domain's value as BigDecimal This method may be used to access the value for this domain in EL-expressions.

### getValue

    public double getValue()

  Return a this domain's value as double This method may be used to access the value for this domain in EL-expressions.

### getData

    public java.lang.Object getData()

  Internal: Applications should not invoke this method. Converts `this` to a JDBC object.
  Specified by:
    `getData` in interface `oracle.jbo.domain.DomainInterface`

### setContext

    public void setContext(oracle.jbo.domain.DomainOwnerInterface owner,
                           oracle.jbo.Transaction trans,
                           java.lang.Object ctx)

  Internal: Applications should not invoke this method.
  Specified by:
    `setContext` in interface `oracle.jbo.domain.DomainInterface`

### toString

    public java.lang.String toString()

  For testing purposes only: converts `this` to a fixed-point number presented as a string.

### equals

    public boolean equals(java.lang.Object other)

  Tests `this` for equality with another object. The argument is converted to a `Number` object, if necessary.
  Parameters:
    `other` - an arbitrary `Object`.
  Returns:
    `true` if conversion was successful and the converted argument is identical to `this`.

### hashCode

    public int hashCode()

  Computes the hash code.
  Returns:
    the hash code of `this`.

### longValue

    public long longValue()

  Calls NUMBER.longValue() to convert internal Oracle Number to a Java long.
  Returns:
    a Java long value

### intValue

    public int intValue()

  Calls NUMBER.intValue() to convert internal Oracle Number to a Java int.
  Returns:
    a Java int value

### shortValue

    public short shortValue()

  Calls NUMBER.shortValue() to convert internal Oracle Number to a Java short.
  Returns:
    a Java short value

### byteValue

    public byte byteValue()

  Calls NUMBER.byteValue() to convert internal Oracle Number to a Java byte.
  Returns:
    a Java byte value

### bigIntegerValue

    public java.math.BigInteger bigIntegerValue()

  Calls NUMBER.bigIntegerValue() to convert internal Oracle Number to a Java BigInteger.
  Returns:
    a Java BigInteger value

### bigDecimalValue

    public java.math.BigDecimal bigDecimalValue()

  Calls NUMBER.bigDecimalValue() to convert internal Oracle Number into a Java BigDecimal.
  Returns:
    a Java BigDecimal value

### add

    public Number add(Number n)

  Adds another number to `this`.
  Parameters:
    `n` - an SQL number.
  Returns:
    a new `Number` object.

### add

    public Number add(double n)

  Adds another number to `this`.
  Parameters:
    `n` - an SQL number.
  Returns:
    a new `Number` object.

### add

    public Number add(int n)

  Adds another number to `this`.
  Parameters:
    `n` - an SQL number.
  Returns:
    a new `Number` object.

### add

    public oracle.sql.NUMBER add(oracle.sql.NUMBER n)

  Adds another number to `this`.
  Parameters:
    `n` - an SQL number.
  Returns:
    a new `Number` object.
  Throws:
    `java.sql.SQLException` - if the Java implementation is not available.

### subtract

    public Number subtract(Number n)

  Subtracts another number from `this`.
  Parameters:
    `n` - an SQL number.
  Returns:
    a new `Number` object.

### subtract

    public Number subtract(double n)

  Subtracts another number from `this`.
  Parameters:
    `n` - a double number
  Returns:
    a new `Number` object.

### subtract

    public Number subtract(int n)

  Subtracts another number from `this`.
  Parameters:
    `n` - a int number
  Returns:
    a new `Number` object.

### subtract

    public oracle.sql.NUMBER subtract(oracle.sql.NUMBER n)

  Subtracts another number from `this`.
  Parameters:
    `n` - an SQL number.
  Returns:
    a new `Number` object.

### multiply

    public Number multiply(Number n)

  Multiplies `this` by another number.
  Parameters:
    `n` - an SQL number.
  Returns:
    a new `Number` object.

### multiply

    public Number multiply(double n)

  Multiplies `this` by another number.
  Parameters:
    `n` - an SQL number.
  Returns:
    a new `Number` object.

### multiply

    public Number multiply(int n)

  Multiplies `this` by another number.
  Parameters:
    `n` - an SQL number.
  Returns:
    a new `Number` object.

### multiply

    public oracle.sql.NUMBER multiply(oracle.sql.NUMBER n)

  Multiplies `this` by another number.
  Parameters:
    `n` - an SQL number.
  Returns:
    a new `Number` object.

### divide

    public Number divide(Number n)

  Divides `this` by another number.
  Parameters:
    `n` - an SQL number.
  Returns:
    a new `Number` object.

### divide

    public Number divide(double n)

  Divides `this` by another number.
  Parameters:
    `n` - an SQL number.
  Returns:
    a new `Number` object.

### divide

    public Number divide(int n)

  Divides `this` by another number.
  Parameters:
    `n` - an SQL number.
  Returns:
    a new `Number` object.

### divide

    public oracle.sql.NUMBER divide(oracle.sql.NUMBER n)

  Divides `this` by another number.
  Parameters:
    `n` - an SQL number.
  Returns:
    a new `Number` object.

### abs

    public oracle.sql.NUMBER abs()

  Finds the absolute value of `this`.
  Returns:
    a new `Number` object.
  Throws:
    ``SQLException`` - if the Java implementation is not available.

### acos

    public oracle.sql.NUMBER acos()

  Calculates the arc cosine of `this`.
  Returns:
    a new `Number` object.

### asin

    public oracle.sql.NUMBER asin()

  Calculates the arc sine of `this`.
  Returns:
    a new `Number` object.

### atan

    public oracle.sql.NUMBER atan()

  Calculates the arc tangent of `this`.
  Returns:
    a new `Number` object.

### atan2

    public Number atan2(Number x)

  Calculates `atan(this, x)`.
  Parameters:
    `x` - an SQL number.
  Returns:
    a new `Number` object.

### atan2

    public oracle.sql.NUMBER atan2(oracle.sql.NUMBER x)

  Calculates `atan(this, x)`.
  Parameters:
    `x` - an SQL number.
  Returns:
    a new `Number` object.
  Throws:
    `java.sql.SQLException` - if the Java implementation is not available.

### ceil

    public oracle.sql.NUMBER ceil()

  Finds the ceiling of `this`.
  Returns:
    a new `Number` object.

### compareTo

    public int compareTo(int n)

  Returns -1 if NUMBER is less than n, 0 if NUMBER and n are equal (==), 1 if NUMBER is greater than n.
  Parameters:
    `n` - input Oracle Number
  Returns:
    integer result of comparison

### compareTo

    public int compareTo(double n)

  Returns -1 if NUMBER is less than n, 0 if NUMBER and n are equal (==), 1 if NUMBER is greater than n.
  Parameters:
    `n` - input Oracle Number
  Returns:
    integer result of comparison

### cos

    public oracle.sql.NUMBER cos()

  Calculates the cosine of `this`.
  Returns:
    a new `Number` object.

### cosh

    public oracle.sql.NUMBER cosh()

  Calculates the hyperbolic cosine of `this`.
  Returns:
    a new `Number` object.

### decrement

    public oracle.sql.NUMBER decrement()

  Subtracts `1` from `this`.
  Returns:
    a new `Number` object.

### div

    public oracle.sql.NUMBER div(oracle.sql.NUMBER n)

  Divides `this` by another number.
  Parameters:
    `n` - an SQL number.
  Returns:
    a new `Number` object.

### exp

    public oracle.sql.NUMBER exp()

  Raises `e` to the power of `this`.
  Returns:
    a new `Number` object.

### floatingPointRound

    public oracle.sql.NUMBER floatingPointRound(int precision)

  Rounds `this` to a specified precision.
  Parameters:
    `precision` - the number of significant decimal places.
  Returns:
    a new `Number` object.

### floor

    public oracle.sql.NUMBER floor()

  Finds the floor of `this`.
  Returns:
    a new `Number` object.

### increment

    public oracle.sql.NUMBER increment()

  Adds `1` to `this`.
  Returns:
    a new `Number` object.

### ln

    public oracle.sql.NUMBER ln()

  Calculates the natural logarithm of `this`.
  Returns:
    a new `Number` object.

### log

    public Number log(Number base)

  Calculates the log of `this` to the specified `base`.
  Parameters:
    `base` - an SQL number.
  Returns:
    a new `Number` object.

### log

    public Number log(double base)

  Calculates the log of `this` to the specified `base`.
  Parameters:
    `base` - an SQL number.
  Returns:
    a new `Number` object.

### log

    public Number log(int base)

  Calculates the log of `this` to the specified `base`.
  Parameters:
    `base` - an SQL number.
  Returns:
    a new `Number` object.

### log

    public oracle.sql.NUMBER log(oracle.sql.NUMBER base)

  Calculates the log of `this` to the specified `base`.
  Parameters:
    `base` - an SQL number.
  Returns:
    a new `Number` object.

### mod

    public Number mod(Number n)

  Calculates the remainder of `this/n`.
  Parameters:
    `n` - an SQL number.
  Returns:
    a new `Number` object.

### mod

    public Number mod(double n)

  Calculates the remainder of `this/n`.
  Parameters:
    `n` - an SQL number.
  Returns:
    a new `Number` object.

### mod

    public Number mod(int n)

  Calculates the remainder of `this/n`.
  Parameters:
    `n` - an SQL number.
  Returns:
    a new `Number` object.

### mod

    public oracle.sql.NUMBER mod(oracle.sql.NUMBER n)

  Calculates the remainder of `this/n`.
  Parameters:
    `n` - an SQL number.
  Returns:
    a new `Number` object.

### mul

    public oracle.sql.NUMBER mul(oracle.sql.NUMBER n)

  Multiplies `this` by another number.
  Parameters:
    `n` - an SQL number.
  Returns:
    a new `Number` object.

### negate

    public oracle.sql.NUMBER negate()

  Calculates `0 - this`.
  Returns:
    a new `Number` object.

### pow

    public Number pow(Number exp)

  Raises `this` to the power of `exp`.
  Parameters:
    `exp` - an SQL number.
  Returns:
    a new `Number` object.

### pow

    public oracle.sql.NUMBER pow(int exp)

  Raises `this` to the power of `exp`.
  Parameters:
    `exp` - a Java 32-bit integer.
  Returns:
    a new `Number` object.

### pow

    public oracle.sql.NUMBER pow(oracle.sql.NUMBER exp)

  Raises `this` to the power of `exp`.
  Parameters:
    `exp` - a Java 32-bit integer.
  Returns:
    a new `Number` object.

### round

    public oracle.sql.NUMBER round(int decimal_place)

  Rounds `this` to a specified precision.
  Parameters:
    `decimal_place` - the number of significant decimal places.
  Returns:
    a Java `int`.

### scale

    public oracle.sql.NUMBER scale(int left,
                                   int right,
                                   boolean[] big)

  Rounds `this` to a specified precision, and tests for excessive magnitude.
  Parameters:
    `left` - the maximum number of decimal digits allowed to the left of the decimal point. If this limit is exceeded `big` is set, but digits are not truncated.
    `right` - the maximum number of decimal digits allowed to the right of the decimal point. The result is rounded to this precision. When this parameter is negative digits to the right of the decimal are forced to zero.
    `big` - a flag set to `true` only if the number of digits left of the decimal exceeds `left`.
  Returns:
    a new `Number` object
  Throws:
    ``SQLException`` - if the Java implementation is not available.

### shift

    public oracle.sql.NUMBER shift(int digits)

  Shift `this` a specified number of decimal places. Positive values shift right, negative values shift left.
  Parameters:
    `digits` - a Java `int`.
  Returns:
    a Java `int`.

### sin

    public oracle.sql.NUMBER sin()

  Calculates the sine of `this`.
  Returns:
    a new `Number` object.

### sinh

    public oracle.sql.NUMBER sinh()

  Calculates the hyperbolic sine of `this`.
  Returns:
    a new `Number` object.

### sqroot

    public oracle.sql.NUMBER sqroot()

  Calculates the square root of `this`.
  Returns:
    a new `Number` object.

### sub

    public oracle.sql.NUMBER sub(oracle.sql.NUMBER n)

  Subtracts another number from `this`.
  Parameters:
    `n` - an SQL number.
  Returns:
    a new `Number` object.

### tan

    public oracle.sql.NUMBER tan()

  Calculates the tangent of `this`.
  Returns:
    a new `Number` object.

### tanh

    public oracle.sql.NUMBER tanh()

  Calculates the hyperbolic tangent of `this`.
  Returns:
    a new `Number` object.

### truncate

    public oracle.sql.NUMBER truncate(int decimal_place)

  Truncates `this`.
  Parameters:
    `decimal_place` - a Java integer.
  Returns:
    a new `Number` object.

### formattedTextToNumber

    public static oracle.sql.NUMBER formattedTextToNumber(java.lang.String num,
                                                          java.lang.String fmt,
                                                          java.lang.String lang)

  Interprets a string as a number.
  Parameters:
    `num` - a string representing a numeric value.
    `fmt` - a format string [see "Oracle 8 Server Concepts Manual" or "CORE User's Guide Appendix D"]
    `lang` - the NLS language the conversion is to be performed in. If null the default language is used.
  Returns:
    a new `Number` object.

### textToPrecisionNumber

    public static oracle.sql.NUMBER textToPrecisionNumber(java.lang.String num,
                                                          boolean precflag,
                                                          int preclen,
                                                          boolean scaleflag,
                                                          int scalelen,
                                                          java.lang.String lang)

  Converts a string to a number with specified precision.
  Parameters:
    `num` - a string representing a numeric value.
    `precflag` - a flag indicating that precision restriction should be applied.
    `preclen` - the maximum number of the decimal digits the result may have, subject to the scale requirement. This argument is ignored if `precflag` is `false`. If the number of digits would otherwise exceed `preclen` the number will be rounded.
    `scaleflag` - a flag indicating that the scale restriction should be applied.
    `scalelen` - the maximum number of decimal places allowed to the right of the decimal point. Negative values are allowed. This argument is ignored if `scaleflag` is `false`. This argument takes precedence over `preclen`. If precision is specified but scale is not, the scale is assumed to be 0.
    `lang` - the NLS language the conversion is to be performed in. If null the default language is used.
  Returns:
    a new `Number` object.

### main

    public static void main(java.lang.String[] argv)
                     throws java.sql.SQLException

  Internal: Applications should not invoke this method.
  Throws:
    `java.sql.SQLException`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Oracle Application Development Framework Business Components Domains Java API Reference 10g Release 3 (10.1.3) B16006-01
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 1997, 2005, Oracle. All rights reserved.