src/Money.php
public function multiply($factor, $roundingMode = PHP_ROUND_HALF_UP)
    {
        if (!in_array($roundingMode, self::$roundingModes)) {
            throw new InvalidArgumentException(
                '$roundingMode ' . \Yii::t('skeeks/money', 'must be a valid rounding mode') . ' (PHP_ROUND_*)'
            );
        }

        return $this->newMoney(
            $this->castToFloat(
                round($factor * $this->amount, 0, $roundingMode)
            )
        );
    }
public function multiply($factor, $roundingMode = PHP_ROUND_HALF_UP)
    {
        if (!in_array($roundingMode, self::$roundingModes)) {
            throw new InvalidArgumentException(
                '$roundingMode ' . \Yii::t('skeeks/money', 'must be a valid rounding mode') . ' (PHP_ROUND_*)'
            );
        }

        return $this->newMoney(
            $this->castToFloat(
                round($factor * $this->amount, 0, $roundingMode)
            )
        );
    }
public function multiply ( $ factor , $ roundingMode = PHP_ROUND_HALF_UP ) { if ( ! in_array ( $ roundingMode , self :: $ roundingModes ) ) { throw new InvalidArgumentException ( '$roundingMode ' . \ Yii :: t ( 'skeeks/money' , 'must be a valid rounding mode' ) . ' (PHP_ROUND_*)' ) ; } return $ this -> newMoney ( $ this -> castToFloat ( round ( $ factor * $ this -> amount , 0 , $ roundingMode ) ) ) ; }
Returns a new Money object that represents the monetary value
of this Money object multiplied by a given factor.

@param  float $factor
@param  integer $roundingMode
@return Money
@throws InvalidArgumentException
Returns a new Money object that represents the monetary value of this Money object multiplied by a given factor .