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