| Total Complexity | 3 |
| Total Lines | 38 |
| Duplicated Lines | 0 % |
| Coverage | 100% |
| Changes | 0 | ||
| 1 | <?php |
||
| 9 | class Transaction implements TransactionInterface |
||
| 10 | { |
||
| 11 | /** |
||
| 12 | * @var string |
||
| 13 | */ |
||
| 14 | private $key; |
||
| 15 | |||
| 16 | /** |
||
| 17 | * @var AbstractDataProvider |
||
| 18 | */ |
||
| 19 | private $dataProvider; |
||
| 20 | |||
| 21 | /** |
||
| 22 | * Transaction constructor. |
||
| 23 | * |
||
| 24 | * @param string $key |
||
| 25 | * @param AbstractDataProvider $dataProvider |
||
| 26 | */ |
||
| 27 | 1 | public function __construct(string $key, AbstractDataProvider $dataProvider) |
|
| 28 | { |
||
| 29 | 1 | $this->key = $key; |
|
| 30 | 1 | $this->dataProvider = $dataProvider; |
|
| 31 | 1 | } |
|
| 32 | |||
| 33 | /** |
||
| 34 | * @return string |
||
| 35 | */ |
||
| 36 | 1 | public function getKey(): string |
|
| 37 | { |
||
| 38 | 1 | return $this->key; |
|
| 39 | } |
||
| 40 | |||
| 41 | /** |
||
| 42 | * @return AbstractDataProvider |
||
| 43 | */ |
||
| 44 | 1 | public function getDataProvider(): AbstractDataProvider |
|
| 47 | } |
||
| 48 | } |