1 | <?php |
||
21 | final class CurrencyStorage implements CurrencyStorageInterface |
||
22 | { |
||
23 | /** |
||
24 | * @var StorageInterface |
||
25 | */ |
||
26 | private $storage; |
||
27 | |||
28 | /** |
||
29 | * @param StorageInterface $storage |
||
30 | */ |
||
31 | public function __construct(StorageInterface $storage) |
||
35 | |||
36 | /** |
||
37 | * {@inheritdoc} |
||
38 | */ |
||
39 | public function set(ChannelInterface $channel, $currencyCode) |
||
49 | |||
50 | /** |
||
51 | * {@inheritdoc} |
||
52 | */ |
||
53 | public function get(ChannelInterface $channel) |
||
57 | |||
58 | /** |
||
59 | * {@inheritdoc} |
||
60 | */ |
||
61 | private function provideKey(ChannelInterface $channel) |
||
65 | |||
66 | /** |
||
67 | * @param string$currencyCode |
||
68 | * @param ChannelInterface $channel |
||
69 | * |
||
70 | * @return bool |
||
71 | */ |
||
72 | private function isBaseCurrency($currencyCode, ChannelInterface $channel) |
||
76 | |||
77 | /** |
||
78 | * @param string $currencyCode |
||
79 | * @param ChannelInterface $channel |
||
80 | * |
||
81 | * @return bool |
||
82 | */ |
||
83 | private function isAvailableCurrency($currencyCode, ChannelInterface $channel) |
||
94 | } |
||
95 |