BankAccount
in package
A bank account.
Tags
Table of Contents
- $balance : float
- The bank account's balance.
- depositMoney() : mixed
- Deposits an amount of money to the bank account.
- getBalance() : float
- Returns the bank account's balance.
- withdrawMoney() : mixed
- Withdraws an amount of money from the bank account.
- setBalance() : mixed
- Sets the bank account's balance.
Properties
$balance
The bank account's balance.
protected
float
$balance
= 0
Methods
depositMoney()
Deposits an amount of money to the bank account.
public
depositMoney(float $balance) : mixed
Parameters
- $balance : float
Tags
Return values
mixed —getBalance()
Returns the bank account's balance.
public
getBalance() : float
Return values
float —withdrawMoney()
Withdraws an amount of money from the bank account.
public
withdrawMoney(float $balance) : mixed
Parameters
- $balance : float
Tags
Return values
mixed —setBalance()
Sets the bank account's balance.
protected
setBalance(float $balance) : mixed
Parameters
- $balance : float