src/League/ServiceServiceProvider.php 1 location
|
@@ 107-115 (lines=9) @@
|
| 104 |
|
* |
| 105 |
|
* @return \Closure |
| 106 |
|
*/ |
| 107 |
|
private function createFactoryFactory(ServiceDefinition $definition) |
| 108 |
|
{ |
| 109 |
|
return function () use ($definition) { |
| 110 |
|
$className = $definition->getClass(); |
| 111 |
|
$factory = new $className(); |
| 112 |
|
|
| 113 |
|
return $factory(...$this->resolveArguments($definition->getArguments())); |
| 114 |
|
}; |
| 115 |
|
} |
| 116 |
|
|
| 117 |
|
/** |
| 118 |
|
* @param array $arguments |
src/Pimple/PimpleContainerAdapter.php 1 location
|
@@ 92-100 (lines=9) @@
|
| 89 |
|
* |
| 90 |
|
* @return \Closure |
| 91 |
|
*/ |
| 92 |
|
private function createFactoryFactory(ServiceDefinition $definition) |
| 93 |
|
{ |
| 94 |
|
return function () use ($definition) { |
| 95 |
|
$className = $definition->getClass(); |
| 96 |
|
$factory = new $className(); |
| 97 |
|
|
| 98 |
|
return $factory(...$this->resolveArguments($definition->getArguments())); |
| 99 |
|
}; |
| 100 |
|
} |
| 101 |
|
|
| 102 |
|
/** |
| 103 |
|
* @param ServiceDefinition $definition |