Instance Method

multiplying(by:)

Multiplies the number by another given number.

Parameters

decimalNumber

The number by which to multiply the receiver.

Return Value

A new NSDecimalNumber object whose value is decimalNumber multiplied by the receiver.

Discussion

This method uses the default behavior when handling calculation errors and when rounding.

Performing Arithmetic

func adding(NSDecimalNumber) -> NSDecimalNumber

Adds this number to another given number.

func subtracting(NSDecimalNumber) -> NSDecimalNumber

Subtracts another given number from this one.

func dividing(by: NSDecimalNumber) -> NSDecimalNumber

Divides the number by another given number.

func raising(toPower: Int) -> NSDecimalNumber

Raises the number to a given power.

func multiplying(byPowerOf10: Int16) -> NSDecimalNumber

Multiplies the number by 10 raised to the given power.

func adding(NSDecimalNumber, withBehavior: NSDecimalNumberBehaviors?) -> NSDecimalNumber

Adds this number to another given number using the specified behavior.

func subtracting(NSDecimalNumber, withBehavior: NSDecimalNumberBehaviors?) -> NSDecimalNumber

Subtracts this a given number from this one using the specified behavior.

func multiplying(by: NSDecimalNumber, withBehavior: NSDecimalNumberBehaviors?) -> NSDecimalNumber

Multiplies this number by another given number using the specified behavior.

func dividing(by: NSDecimalNumber, withBehavior: NSDecimalNumberBehaviors?) -> NSDecimalNumber

Divides this number by another given number using the specified behavior.

func raising(toPower: Int, withBehavior: NSDecimalNumberBehaviors?) -> NSDecimalNumber

Raises the number to a given power using the specified behavior.

func multiplying(byPowerOf10: Int16, withBehavior: NSDecimalNumberBehaviors?) -> NSDecimalNumber

Multiplies the number by 10 raised to the given power using the specified behavior.