Instance Method

initWithDecimal:

Initializes a decimal number to represent a given decimal.

Declaration

- (instancetype)initWithDecimal:(NSDecimal)dcm;

Parameters

decimal

The value of the new object.

Return Value

An NSDecimalNumber object initialized to represent decimal.

Discussion

This method is the designated initializer for NSDecimalNumber.

See Also

Initializing a Decimal Number

- initWithMantissa:exponent:isNegative:

Initializes a decimal number using the given mantissa, exponent, and sign.

- initWithString:

Initializes a decimal number so that its value is equivalent to that in a given numeric string.

- initWithString:locale:

Initializes a decimal number so that its value is equivalent to that in a given numeric string, interpreted using a given locale.