| 1 | <?php |
||
| 10 | class Money |
||
| 11 | { |
||
| 12 | /** |
||
| 13 | * @var double |
||
| 14 | */ |
||
| 15 | protected $amount; |
||
| 16 | /** |
||
| 17 | * @var string |
||
| 18 | */ |
||
| 19 | protected $currency; |
||
| 20 | |||
| 21 | /** |
||
| 22 | * Money constructor. |
||
| 23 | * @param float $amount |
||
| 24 | * @param string $currency |
||
| 25 | */ |
||
| 26 | public function __construct($amount = null, $currency = null) |
||
| 31 | |||
| 32 | /** |
||
| 33 | * @return float |
||
| 34 | */ |
||
| 35 | public function getAmount() |
||
| 39 | |||
| 40 | /** |
||
| 41 | * @param double $amount |
||
| 42 | * @return $this |
||
| 43 | */ |
||
| 44 | public function setAmount($amount) |
||
| 50 | |||
| 51 | |||
| 52 | /** |
||
| 53 | * @return string |
||
| 54 | */ |
||
| 55 | public function getCurrency() |
||
| 59 | |||
| 60 | /** |
||
| 61 | * @param string $currency |
||
| 62 | * @return $this |
||
| 63 | */ |
||
| 64 | public function setCurrency($currency) |
||
| 70 | } |
||
| 71 |