| 1 | <?php |
||
| 5 | class SizeDriverFactory |
||
| 6 | { |
||
| 7 | /** |
||
| 8 | * @var ISizeDriver[] |
||
| 9 | */ |
||
| 10 | private $drivers = []; |
||
| 11 | |||
| 12 | /** |
||
| 13 | * @var Exception[] |
||
| 14 | */ |
||
| 15 | private $exceptions = []; |
||
| 16 | |||
| 17 | /** |
||
| 18 | * @param string[]|callable[] $drivers names of classes to build |
||
| 19 | */ |
||
| 20 | public function __construct(array $drivers) |
||
| 38 | |||
| 39 | private function addDriver(ISizeDriver $driver) { |
||
| 42 | |||
| 43 | /** |
||
| 44 | * @return ISizeDriver[] |
||
| 45 | */ |
||
| 46 | public function getInitializedDrivers() |
||
| 50 | |||
| 51 | /** |
||
| 52 | * @return Exception[] |
||
| 53 | */ |
||
| 54 | public function getInitializationExceptions() |
||
| 58 | } |
||
| 59 |