| Total Complexity | 3 |
| Total Lines | 27 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 22 | class ServiceLocator implements ServiceLocatorInterface |
||
| 23 | { |
||
| 24 | protected $objectManager; |
||
| 25 | |||
| 26 | /** |
||
| 27 | * ServiceLocator constructor. |
||
| 28 | * @param MagentoObjectManagerInterface $objectManager |
||
| 29 | * Using composition over inheritance of course |
||
| 30 | */ |
||
| 31 | public function __construct( |
||
| 35 | } |
||
| 36 | |||
| 37 | /** |
||
| 38 | * @param $class |
||
| 39 | * @return mixed |
||
| 40 | */ |
||
| 41 | public function get($class) |
||
| 42 | { |
||
| 43 | return $this->objectManager->get($class); |
||
| 44 | } |
||
| 45 | |||
| 46 | public function create($class, array $arguments = []) |
||
| 49 | } |
||
| 50 | } |
||
| 51 |