public function BankAccount::depositMoney in Zircon Profile 8.0
Same name in this branch
- 8.0 vendor/phpunit/phpunit/tests/_files/BankAccount.php \BankAccount::depositMoney()
- 8.0 vendor/phpunit/php-code-coverage/tests/_files/BankAccount.php \BankAccount::depositMoney()
Same name and namespace in other branches
- 8 vendor/phpunit/phpunit/tests/_files/BankAccount.php \BankAccount::depositMoney()
- 8 vendor/phpunit/php-code-coverage/tests/_files/BankAccount.php \BankAccount::depositMoney()
Deposits an amount of money to the bank account.
Parameters
float $balance:
Throws
File
- vendor/
phpunit/ phpunit/ tests/ _files/ BankAccount.php, line 60
Class
- BankAccount
- A bank account.
Code
public function depositMoney($balance) {
$this
->setBalance($this
->getBalance() + $balance);
return $this
->getBalance();
}