1 | <?php |
||
19 | class OpenExchangeRatesDriver implements CurrencyDriverInterface |
||
20 | { |
||
21 | /** |
||
22 | * @var string |
||
23 | */ |
||
24 | private $appId; |
||
25 | |||
26 | /** |
||
27 | * @var null|Client |
||
28 | */ |
||
29 | private $httpClient; |
||
30 | |||
31 | /** |
||
32 | * @return string |
||
33 | */ |
||
34 | public function getAppId() |
||
38 | |||
39 | /** |
||
40 | * @param string $appId |
||
41 | */ |
||
42 | public function setAppId($appId) |
||
46 | |||
47 | /** |
||
48 | * @param null|Client $httpClient |
||
49 | */ |
||
50 | public function __construct(Client $httpClient = null) |
||
54 | |||
55 | /** |
||
56 | * Downloads raw currency data. |
||
57 | * |
||
58 | * @return array |
||
59 | */ |
||
60 | private function getRawData() |
||
69 | |||
70 | /** |
||
71 | * {@inheritdoc} |
||
72 | */ |
||
73 | public function getRates() |
||
95 | |||
96 | /** |
||
97 | * {@inheritdoc} |
||
98 | */ |
||
99 | public function getBaseCurrency() |
||
103 | } |
||
104 |