@@ -134,7 +134,7 @@ discard block |
||
| 134 | 134 | /** |
| 135 | 135 | * @param Container $container |
| 136 | 136 | * |
| 137 | - * @return callable |
|
| 137 | + * @return \Closure |
|
| 138 | 138 | */ |
| 139 | 139 | private function getOrmEmsDefinition(Container $container): callable |
| 140 | 140 | { |
@@ -166,7 +166,7 @@ discard block |
||
| 166 | 166 | /** |
| 167 | 167 | * @param Container $container |
| 168 | 168 | * |
| 169 | - * @return callable |
|
| 169 | + * @return \Closure |
|
| 170 | 170 | */ |
| 171 | 171 | private function getOrmEmsConfigServiceProvider(Container $container): callable |
| 172 | 172 | { |
@@ -187,7 +187,7 @@ discard block |
||
| 187 | 187 | * @param string $name |
| 188 | 188 | * @param array $options |
| 189 | 189 | * |
| 190 | - * @return callable |
|
| 190 | + * @return \Closure |
|
| 191 | 191 | */ |
| 192 | 192 | private function getOrmEmConfigByNameAndOptionsDefinition( |
| 193 | 193 | Container $container, |
@@ -528,7 +528,7 @@ discard block |
||
| 528 | 528 | /** |
| 529 | 529 | * @param Container $container |
| 530 | 530 | * |
| 531 | - * @return callable |
|
| 531 | + * @return \Closure |
|
| 532 | 532 | */ |
| 533 | 533 | private function getOrmNamingStrategyDefinition(Container $container): callable |
| 534 | 534 | { |
@@ -540,7 +540,7 @@ discard block |
||
| 540 | 540 | /** |
| 541 | 541 | * @param Container $container |
| 542 | 542 | * |
| 543 | - * @return callable |
|
| 543 | + * @return \Closure |
|
| 544 | 544 | */ |
| 545 | 545 | private function getOrmQuoteStrategyDefinition(Container $container): callable |
| 546 | 546 | { |
@@ -552,7 +552,7 @@ discard block |
||
| 552 | 552 | /** |
| 553 | 553 | * @param Container $container |
| 554 | 554 | * |
| 555 | - * @return callable |
|
| 555 | + * @return \Closure |
|
| 556 | 556 | */ |
| 557 | 557 | private function getOrmEntityListenerResolverDefinition(Container $container): callable |
| 558 | 558 | { |
@@ -564,7 +564,7 @@ discard block |
||
| 564 | 564 | /** |
| 565 | 565 | * @param Container $container |
| 566 | 566 | * |
| 567 | - * @return callable |
|
| 567 | + * @return \Closure |
|
| 568 | 568 | */ |
| 569 | 569 | private function getOrmRepositoryFactoryDefinition(Container $container): callable |
| 570 | 570 | { |
@@ -576,7 +576,7 @@ discard block |
||
| 576 | 576 | /** |
| 577 | 577 | * @param Container $container |
| 578 | 578 | * |
| 579 | - * @return callable |
|
| 579 | + * @return \Closure |
|
| 580 | 580 | */ |
| 581 | 581 | private function getOrmSecondLevelCacheConfigurationDefinition(Container $container): callable |
| 582 | 582 | { |
@@ -588,7 +588,7 @@ discard block |
||
| 588 | 588 | /** |
| 589 | 589 | * @param Container $container |
| 590 | 590 | * |
| 591 | - * @return callable |
|
| 591 | + * @return \Closure |
|
| 592 | 592 | */ |
| 593 | 593 | private function getOrmEmDefinition(Container $container): callable |
| 594 | 594 | { |
@@ -602,7 +602,7 @@ discard block |
||
| 602 | 602 | /** |
| 603 | 603 | * @param Container $container |
| 604 | 604 | * |
| 605 | - * @return callable |
|
| 605 | + * @return \Closure |
|
| 606 | 606 | */ |
| 607 | 607 | private function getOrmEmConfigDefinition(Container $container): callable |
| 608 | 608 | { |
@@ -88,7 +88,7 @@ discard block |
||
| 88 | 88 | */ |
| 89 | 89 | private function getOrmEmsOptionsInitializerDefinition(Container $container): callable |
| 90 | 90 | { |
| 91 | - return $container->protect(function () use ($container) { |
|
| 91 | + return $container->protect(function() use ($container) { |
|
| 92 | 92 | static $initialized = false; |
| 93 | 93 | |
| 94 | 94 | if ($initialized) { |
@@ -123,7 +123,7 @@ discard block |
||
| 123 | 123 | */ |
| 124 | 124 | private function getOrmEmsDefinition(Container $container): callable |
| 125 | 125 | { |
| 126 | - return function () use ($container) { |
|
| 126 | + return function() use ($container) { |
|
| 127 | 127 | $container['doctrine.orm.ems.options.initializer'](); |
| 128 | 128 | |
| 129 | 129 | $ems = new Container(); |
@@ -135,7 +135,7 @@ discard block |
||
| 135 | 135 | $config = $container['doctrine.orm.ems.config'][$name]; |
| 136 | 136 | } |
| 137 | 137 | |
| 138 | - $ems[$name] = function () use ($container, $options, $config) { |
|
| 138 | + $ems[$name] = function() use ($container, $options, $config) { |
|
| 139 | 139 | return EntityManager::create( |
| 140 | 140 | $container['doctrine.dbal.dbs'][$options['connection']], |
| 141 | 141 | $config, |
@@ -155,7 +155,7 @@ discard block |
||
| 155 | 155 | */ |
| 156 | 156 | private function getOrmEmsConfigServiceProvider(Container $container): callable |
| 157 | 157 | { |
| 158 | - return function () use ($container) { |
|
| 158 | + return function() use ($container) { |
|
| 159 | 159 | $container['doctrine.orm.ems.options.initializer'](); |
| 160 | 160 | |
| 161 | 161 | $configs = new Container(); |
@@ -179,7 +179,7 @@ discard block |
||
| 179 | 179 | string $name, |
| 180 | 180 | array $options |
| 181 | 181 | ): callable { |
| 182 | - return function () use ($container, $name, $options) { |
|
| 182 | + return function() use ($container, $name, $options) { |
|
| 183 | 183 | $config = new Configuration(); |
| 184 | 184 | |
| 185 | 185 | $config->setProxyDir($container['doctrine.orm.proxies_dir']); |
@@ -239,7 +239,7 @@ discard block |
||
| 239 | 239 | */ |
| 240 | 240 | private function getOrmMappingDriverChainDefinition(Container $container): callable |
| 241 | 241 | { |
| 242 | - return $container->protect(function (string $name, Configuration $config, array $mappings) use ($container) { |
|
| 242 | + return $container->protect(function(string $name, Configuration $config, array $mappings) use ($container) { |
|
| 243 | 243 | $container['doctrine.orm.ems.options.initializer'](); |
| 244 | 244 | |
| 245 | 245 | /** @var MappingDriverChain $chain */ |
@@ -276,7 +276,7 @@ discard block |
||
| 276 | 276 | */ |
| 277 | 277 | private function getOrmMappingDriverChainFactoryDefinition(Container $container): callable |
| 278 | 278 | { |
| 279 | - return $container->protect(function () use ($container) { |
|
| 279 | + return $container->protect(function() use ($container) { |
|
| 280 | 280 | return new MappingDriverChain(); |
| 281 | 281 | }); |
| 282 | 282 | } |
@@ -288,7 +288,7 @@ discard block |
||
| 288 | 288 | */ |
| 289 | 289 | private function getOrmMappingDriverFactoryAnnotation(Container $container): callable |
| 290 | 290 | { |
| 291 | - return $container->protect(function (array $entity, Configuration $config) { |
|
| 291 | + return $container->protect(function(array $entity, Configuration $config) { |
|
| 292 | 292 | $useSimpleAnnotationReader = $entity['use_simple_annotation_reader'] ?? true; |
| 293 | 293 | |
| 294 | 294 | return $config->newDefaultAnnotationDriver( |
@@ -305,7 +305,7 @@ discard block |
||
| 305 | 305 | */ |
| 306 | 306 | private function getOrmMappingDriverFactoryYaml(Container $container): callable |
| 307 | 307 | { |
| 308 | - return $container->protect(function (array $entity, Configuration $config) { |
|
| 308 | + return $container->protect(function(array $entity, Configuration $config) { |
|
| 309 | 309 | return new YamlDriver($entity['path']); |
| 310 | 310 | }); |
| 311 | 311 | } |
@@ -317,7 +317,7 @@ discard block |
||
| 317 | 317 | */ |
| 318 | 318 | private function getOrmMappingDriverFactorySimpleYaml(Container $container): callable |
| 319 | 319 | { |
| 320 | - return $container->protect(function (array $entity, Configuration $config) { |
|
| 320 | + return $container->protect(function(array $entity, Configuration $config) { |
|
| 321 | 321 | return new SimplifiedYamlDriver([$entity['path'] => $entity['namespace']]); |
| 322 | 322 | }); |
| 323 | 323 | } |
@@ -329,7 +329,7 @@ discard block |
||
| 329 | 329 | */ |
| 330 | 330 | private function getOrmMappingDriverFactoryXml(Container $container): callable |
| 331 | 331 | { |
| 332 | - return $container->protect(function (array $entity, Configuration $config) { |
|
| 332 | + return $container->protect(function(array $entity, Configuration $config) { |
|
| 333 | 333 | return new XmlDriver($entity['path']); |
| 334 | 334 | }); |
| 335 | 335 | } |
@@ -341,7 +341,7 @@ discard block |
||
| 341 | 341 | */ |
| 342 | 342 | private function getOrmMappingDriverFactorySimpleXml(Container $container): callable |
| 343 | 343 | { |
| 344 | - return $container->protect(function (array $entity, Configuration $config) { |
|
| 344 | + return $container->protect(function(array $entity, Configuration $config) { |
|
| 345 | 345 | return new SimplifiedXmlDriver([$entity['path'] => $entity['namespace']]); |
| 346 | 346 | }); |
| 347 | 347 | } |
@@ -353,7 +353,7 @@ discard block |
||
| 353 | 353 | */ |
| 354 | 354 | private function getOrmMappingDriverFactoryPhp(Container $container): callable |
| 355 | 355 | { |
| 356 | - return $container->protect(function (array $entity, Configuration $config) { |
|
| 356 | + return $container->protect(function(array $entity, Configuration $config) { |
|
| 357 | 357 | return new StaticPHPDriver($entity['path']); |
| 358 | 358 | }); |
| 359 | 359 | } |
@@ -365,7 +365,7 @@ discard block |
||
| 365 | 365 | */ |
| 366 | 366 | private function getOrmNamingStrategyDefinition(Container $container): callable |
| 367 | 367 | { |
| 368 | - return function () use ($container) { |
|
| 368 | + return function() use ($container) { |
|
| 369 | 369 | return new DefaultNamingStrategy(); |
| 370 | 370 | }; |
| 371 | 371 | } |
@@ -377,7 +377,7 @@ discard block |
||
| 377 | 377 | */ |
| 378 | 378 | private function getOrmQuoteStrategyDefinition(Container $container): callable |
| 379 | 379 | { |
| 380 | - return function () use ($container) { |
|
| 380 | + return function() use ($container) { |
|
| 381 | 381 | return new DefaultQuoteStrategy(); |
| 382 | 382 | }; |
| 383 | 383 | } |
@@ -389,7 +389,7 @@ discard block |
||
| 389 | 389 | */ |
| 390 | 390 | private function getOrmEntityListenerResolverDefinition(Container $container): callable |
| 391 | 391 | { |
| 392 | - return function () use ($container) { |
|
| 392 | + return function() use ($container) { |
|
| 393 | 393 | return new DefaultEntityListenerResolver(); |
| 394 | 394 | }; |
| 395 | 395 | } |
@@ -401,7 +401,7 @@ discard block |
||
| 401 | 401 | */ |
| 402 | 402 | private function getOrmRepositoryFactoryDefinition(Container $container): callable |
| 403 | 403 | { |
| 404 | - return function () use ($container) { |
|
| 404 | + return function() use ($container) { |
|
| 405 | 405 | return new DefaultRepositoryFactory(); |
| 406 | 406 | }; |
| 407 | 407 | } |
@@ -413,7 +413,7 @@ discard block |
||
| 413 | 413 | */ |
| 414 | 414 | private function getOrmSecondLevelCacheConfigurationDefinition(Container $container): callable |
| 415 | 415 | { |
| 416 | - return function () use ($container) { |
|
| 416 | + return function() use ($container) { |
|
| 417 | 417 | return new CacheConfiguration(); |
| 418 | 418 | }; |
| 419 | 419 | } |
@@ -425,7 +425,7 @@ discard block |
||
| 425 | 425 | */ |
| 426 | 426 | private function getOrmEmDefinition(Container $container): callable |
| 427 | 427 | { |
| 428 | - return function () use ($container) { |
|
| 428 | + return function() use ($container) { |
|
| 429 | 429 | $ems = $container['doctrine.orm.ems']; |
| 430 | 430 | |
| 431 | 431 | return $ems[$container['doctrine.orm.ems.default']]; |
@@ -439,7 +439,7 @@ discard block |
||
| 439 | 439 | */ |
| 440 | 440 | private function getOrmEmConfigDefinition(Container $container): callable |
| 441 | 441 | { |
| 442 | - return function () use ($container) { |
|
| 442 | + return function() use ($container) { |
|
| 443 | 443 | $configs = $container['doctrine.orm.ems.config']; |
| 444 | 444 | |
| 445 | 445 | return $configs[$container['doctrine.orm.ems.default']]; |
@@ -36,7 +36,7 @@ discard block |
||
| 36 | 36 | /** |
| 37 | 37 | * @param Container $container |
| 38 | 38 | * |
| 39 | - * @return callable |
|
| 39 | + * @return \Closure |
|
| 40 | 40 | */ |
| 41 | 41 | private function getLoggerDefinition(Container $container): callable |
| 42 | 42 | { |
@@ -48,7 +48,7 @@ discard block |
||
| 48 | 48 | /** |
| 49 | 49 | * @param Container $container |
| 50 | 50 | * |
| 51 | - * @return callable |
|
| 51 | + * @return \Closure |
|
| 52 | 52 | */ |
| 53 | 53 | private function getMonologDefinition(Container $container): callable |
| 54 | 54 | { |
@@ -63,7 +63,7 @@ discard block |
||
| 63 | 63 | /** |
| 64 | 64 | * @param Container $container |
| 65 | 65 | * |
| 66 | - * @return callable |
|
| 66 | + * @return \Closure |
|
| 67 | 67 | */ |
| 68 | 68 | private function getMonologFormatterDefinition(Container $container): callable |
| 69 | 69 | { |
@@ -75,7 +75,7 @@ discard block |
||
| 75 | 75 | /** |
| 76 | 76 | * @param Container $container |
| 77 | 77 | * |
| 78 | - * @return callable |
|
| 78 | + * @return \Closure |
|
| 79 | 79 | */ |
| 80 | 80 | private function getMonologHandlersDefinition(Container $container): callable |
| 81 | 81 | { |
@@ -87,7 +87,7 @@ discard block |
||
| 87 | 87 | /** |
| 88 | 88 | * @param Container $container |
| 89 | 89 | * |
| 90 | - * @return callable |
|
| 90 | + * @return \Closure |
|
| 91 | 91 | */ |
| 92 | 92 | private function getMonologDefaultHandlerDefinition(Container $container): callable |
| 93 | 93 | { |
@@ -40,7 +40,7 @@ discard block |
||
| 40 | 40 | */ |
| 41 | 41 | private function getLoggerDefinition(Container $container): callable |
| 42 | 42 | { |
| 43 | - return function () use ($container) { |
|
| 43 | + return function() use ($container) { |
|
| 44 | 44 | return $container['monolog']; |
| 45 | 45 | }; |
| 46 | 46 | } |
@@ -52,7 +52,7 @@ discard block |
||
| 52 | 52 | */ |
| 53 | 53 | private function getMonologDefinition(Container $container): callable |
| 54 | 54 | { |
| 55 | - return function ($container) { |
|
| 55 | + return function($container) { |
|
| 56 | 56 | $log = new Logger($container['monolog.name']); |
| 57 | 57 | $log->pushHandler(new GroupHandler($container['monolog.handlers'])); |
| 58 | 58 | |
@@ -67,7 +67,7 @@ discard block |
||
| 67 | 67 | */ |
| 68 | 68 | private function getMonologFormatterDefinition(Container $container): callable |
| 69 | 69 | { |
| 70 | - return function () { |
|
| 70 | + return function() { |
|
| 71 | 71 | return new LineFormatter(); |
| 72 | 72 | }; |
| 73 | 73 | } |
@@ -79,7 +79,7 @@ discard block |
||
| 79 | 79 | */ |
| 80 | 80 | private function getMonologHandlersDefinition(Container $container): callable |
| 81 | 81 | { |
| 82 | - return function () use ($container) { |
|
| 82 | + return function() use ($container) { |
|
| 83 | 83 | return [$container['monolog.default_handler']]; |
| 84 | 84 | }; |
| 85 | 85 | } |
@@ -91,7 +91,7 @@ discard block |
||
| 91 | 91 | */ |
| 92 | 92 | private function getMonologDefaultHandlerDefinition(Container $container): callable |
| 93 | 93 | { |
| 94 | - return function () use ($container) { |
|
| 94 | + return function() use ($container) { |
|
| 95 | 95 | $handler = new StreamHandler( |
| 96 | 96 | $container['monolog.logfile'], |
| 97 | 97 | $container['monolog.level'], |
@@ -53,7 +53,7 @@ discard block |
||
| 53 | 53 | */ |
| 54 | 54 | private function getDbsOptionsInitializerDefinition(Container $container): callable |
| 55 | 55 | { |
| 56 | - return $container->protect(function () use ($container) { |
|
| 56 | + return $container->protect(function() use ($container) { |
|
| 57 | 57 | static $initialized = false; |
| 58 | 58 | |
| 59 | 59 | if ($initialized) { |
@@ -88,7 +88,7 @@ discard block |
||
| 88 | 88 | */ |
| 89 | 89 | private function getDbsDefinition(Container $container): callable |
| 90 | 90 | { |
| 91 | - return function () use ($container) { |
|
| 91 | + return function() use ($container) { |
|
| 92 | 92 | $container['doctrine.dbal.dbs.options.initializer'](); |
| 93 | 93 | |
| 94 | 94 | $dbs = new Container(); |
@@ -102,7 +102,7 @@ discard block |
||
| 102 | 102 | $manager = $container['doctrine.dbal.dbs.event_manager'][$name]; |
| 103 | 103 | } |
| 104 | 104 | |
| 105 | - $dbs[$name] = function () use ($options, $config, $manager) { |
|
| 105 | + $dbs[$name] = function() use ($options, $config, $manager) { |
|
| 106 | 106 | return DriverManager::getConnection($options, $config, $manager); |
| 107 | 107 | }; |
| 108 | 108 | } |
@@ -118,14 +118,14 @@ discard block |
||
| 118 | 118 | */ |
| 119 | 119 | private function getDbsConfigDefinition(Container $container): callable |
| 120 | 120 | { |
| 121 | - return function () use ($container) { |
|
| 121 | + return function() use ($container) { |
|
| 122 | 122 | $container['doctrine.dbal.dbs.options.initializer'](); |
| 123 | 123 | |
| 124 | 124 | $addLogger = $container['logger'] ?? false; |
| 125 | 125 | |
| 126 | 126 | $configs = new Container(); |
| 127 | 127 | foreach ($container['doctrine.dbal.dbs.options'] as $name => $options) { |
| 128 | - $configs[$name] = function () use ($addLogger, $container) { |
|
| 128 | + $configs[$name] = function() use ($addLogger, $container) { |
|
| 129 | 129 | $config = new Configuration(); |
| 130 | 130 | if ($addLogger) { |
| 131 | 131 | $config->setSQLLogger(new DoctrineDbalLogger($container['logger'])); |
@@ -146,12 +146,12 @@ discard block |
||
| 146 | 146 | */ |
| 147 | 147 | private function getDbsEventManagerDefinition(Container $container): callable |
| 148 | 148 | { |
| 149 | - return function () use ($container) { |
|
| 149 | + return function() use ($container) { |
|
| 150 | 150 | $container['doctrine.dbal.dbs.options.initializer'](); |
| 151 | 151 | |
| 152 | 152 | $managers = new Container(); |
| 153 | 153 | foreach ($container['doctrine.dbal.dbs.options'] as $name => $options) { |
| 154 | - $managers[$name] = function () { |
|
| 154 | + $managers[$name] = function() { |
|
| 155 | 155 | return new EventManager(); |
| 156 | 156 | }; |
| 157 | 157 | } |
@@ -166,7 +166,7 @@ discard block |
||
| 166 | 166 | */ |
| 167 | 167 | private function getDbDefinition(Container $container): callable |
| 168 | 168 | { |
| 169 | - return function () use ($container) { |
|
| 169 | + return function() use ($container) { |
|
| 170 | 170 | $dbs = $container['doctrine.dbal.dbs']; |
| 171 | 171 | |
| 172 | 172 | return $dbs[$container['doctrine.dbal.dbs.default']]; |
@@ -179,7 +179,7 @@ discard block |
||
| 179 | 179 | */ |
| 180 | 180 | private function getDbConfigDefinition(Container $container): callable |
| 181 | 181 | { |
| 182 | - return function () use ($container) { |
|
| 182 | + return function() use ($container) { |
|
| 183 | 183 | $dbs = $container['doctrine.dbal.dbs.config']; |
| 184 | 184 | |
| 185 | 185 | return $dbs[$container['doctrine.dbal.dbs.default']]; |
@@ -192,7 +192,7 @@ discard block |
||
| 192 | 192 | */ |
| 193 | 193 | private function getDbEventManagerDefinition(Container $container): callable |
| 194 | 194 | { |
| 195 | - return function () use ($container) { |
|
| 195 | + return function() use ($container) { |
|
| 196 | 196 | $dbs = $container['doctrine.dbal.dbs.event_manager']; |
| 197 | 197 | |
| 198 | 198 | return $dbs[$container['doctrine.dbal.dbs.default']]; |
@@ -49,7 +49,7 @@ discard block |
||
| 49 | 49 | */ |
| 50 | 50 | private function getMongoDbsOptionsInitializerDefinition(Container $container): callable |
| 51 | 51 | { |
| 52 | - return $container->protect(function () use ($container) { |
|
| 52 | + return $container->protect(function() use ($container) { |
|
| 53 | 53 | static $initialized = false; |
| 54 | 54 | |
| 55 | 55 | if ($initialized) { |
@@ -84,7 +84,7 @@ discard block |
||
| 84 | 84 | */ |
| 85 | 85 | private function getMongoDbsDefinition(Container $container): callable |
| 86 | 86 | { |
| 87 | - return function () use ($container) { |
|
| 87 | + return function() use ($container) { |
|
| 88 | 88 | $container['doctrine.mongo.dbs.options.initializer'](); |
| 89 | 89 | |
| 90 | 90 | $mongodbs = new Container(); |
@@ -98,7 +98,7 @@ discard block |
||
| 98 | 98 | $manager = $container['doctrine.mongo.dbs.event_manager'][$name]; |
| 99 | 99 | } |
| 100 | 100 | |
| 101 | - $mongodbs[$name] = function () use ($options, $config, $manager) { |
|
| 101 | + $mongodbs[$name] = function() use ($options, $config, $manager) { |
|
| 102 | 102 | return new Connection($options['server'], $options['options'], $config, $manager); |
| 103 | 103 | }; |
| 104 | 104 | } |
@@ -114,14 +114,14 @@ discard block |
||
| 114 | 114 | */ |
| 115 | 115 | private function getMongoDbsConfigDefinition(Container $container): callable |
| 116 | 116 | { |
| 117 | - return function () use ($container) { |
|
| 117 | + return function() use ($container) { |
|
| 118 | 118 | $container['doctrine.mongo.dbs.options.initializer'](); |
| 119 | 119 | |
| 120 | 120 | $addLogger = $container['logger'] ?? false; |
| 121 | 121 | |
| 122 | 122 | $configs = new Container(); |
| 123 | 123 | foreach ($container['doctrine.mongo.dbs.options'] as $name => $options) { |
| 124 | - $configs[$name] = function () use ($addLogger, $container) { |
|
| 124 | + $configs[$name] = function() use ($addLogger, $container) { |
|
| 125 | 125 | $config = new Configuration(); |
| 126 | 126 | if ($addLogger) { |
| 127 | 127 | $logger = new DoctrineMongoLogger( |
@@ -147,12 +147,12 @@ discard block |
||
| 147 | 147 | */ |
| 148 | 148 | private function getMongoDbsEventManagerDefinition(Container $container): callable |
| 149 | 149 | { |
| 150 | - return function () use ($container) { |
|
| 150 | + return function() use ($container) { |
|
| 151 | 151 | $container['doctrine.mongo.dbs.options.initializer'](); |
| 152 | 152 | |
| 153 | 153 | $managers = new Container(); |
| 154 | 154 | foreach ($container['doctrine.mongo.dbs.options'] as $name => $options) { |
| 155 | - $managers[$name] = function () { |
|
| 155 | + $managers[$name] = function() { |
|
| 156 | 156 | return new EventManager(); |
| 157 | 157 | }; |
| 158 | 158 | } |
@@ -167,7 +167,7 @@ discard block |
||
| 167 | 167 | */ |
| 168 | 168 | private function getMongoDbDefinition(Container $container): callable |
| 169 | 169 | { |
| 170 | - return function () use ($container) { |
|
| 170 | + return function() use ($container) { |
|
| 171 | 171 | $dbs = $container['doctrine.mongo.dbs']; |
| 172 | 172 | |
| 173 | 173 | return $dbs[$container['doctrine.mongo.dbs.default']]; |
@@ -180,7 +180,7 @@ discard block |
||
| 180 | 180 | */ |
| 181 | 181 | private function getMongoDbConfigDefinition(Container $container): callable |
| 182 | 182 | { |
| 183 | - return function () use ($container) { |
|
| 183 | + return function() use ($container) { |
|
| 184 | 184 | $dbs = $container['doctrine.mongo.dbs.config']; |
| 185 | 185 | |
| 186 | 186 | return $dbs[$container['doctrine.mongo.dbs.default']]; |
@@ -193,7 +193,7 @@ discard block |
||
| 193 | 193 | */ |
| 194 | 194 | private function getMongoDbEventManagerDefinition(Container $container): callable |
| 195 | 195 | { |
| 196 | - return function () use ($container) { |
|
| 196 | + return function() use ($container) { |
|
| 197 | 197 | $dbs = $container['doctrine.mongo.dbs.event_manager']; |
| 198 | 198 | |
| 199 | 199 | return $dbs[$container['doctrine.mongo.dbs.default']]; |
@@ -49,7 +49,7 @@ |
||
| 49 | 49 | $query['data'] = '**'.$query['num'].' item(s)**'; |
| 50 | 50 | } |
| 51 | 51 | |
| 52 | - array_walk_recursive($query, function (&$value) { |
|
| 52 | + array_walk_recursive($query, function(&$value) { |
|
| 53 | 53 | $value = $this->flatValue($value); |
| 54 | 54 | }); |
| 55 | 55 | |
@@ -44,7 +44,7 @@ discard block |
||
| 44 | 44 | */ |
| 45 | 45 | private function getOrmCacheLocatorDefinition(Container $container): callable |
| 46 | 46 | { |
| 47 | - return $container->protect(function (string $key, array $options) use ($container) { |
|
| 47 | + return $container->protect(function(string $key, array $options) use ($container) { |
|
| 48 | 48 | $cacheInstanceKey = 'orm.cache.instances.'.$key; |
| 49 | 49 | if (isset($container[$cacheInstanceKey])) { |
| 50 | 50 | return $container[$cacheInstanceKey]; |
@@ -74,7 +74,7 @@ discard block |
||
| 74 | 74 | */ |
| 75 | 75 | private function getOrmCacheFactoryDefinition(Container $container): callable |
| 76 | 76 | { |
| 77 | - return $container->protect(function (string $driver, array $options) use ($container) { |
|
| 77 | + return $container->protect(function(string $driver, array $options) use ($container) { |
|
| 78 | 78 | $cacheFactoryKey = 'doctrine.cache.factory.'.$driver; |
| 79 | 79 | if (!isset($container[$cacheFactoryKey])) { |
| 80 | 80 | throw new \RuntimeException( |
@@ -93,7 +93,7 @@ discard block |
||
| 93 | 93 | */ |
| 94 | 94 | private function getOrmCacheFactoryApcuDefinition(Container $container): callable |
| 95 | 95 | { |
| 96 | - return $container->protect(function () use ($container) { |
|
| 96 | + return $container->protect(function() use ($container) { |
|
| 97 | 97 | return new ApcuCache(); |
| 98 | 98 | }); |
| 99 | 99 | } |
@@ -105,7 +105,7 @@ discard block |
||
| 105 | 105 | */ |
| 106 | 106 | private function getOrmCacheFactoryArrayDefinition(Container $container): callable |
| 107 | 107 | { |
| 108 | - return $container->protect(function () use ($container) { |
|
| 108 | + return $container->protect(function() use ($container) { |
|
| 109 | 109 | return new ArrayCache(); |
| 110 | 110 | }); |
| 111 | 111 | } |
@@ -117,7 +117,7 @@ discard block |
||
| 117 | 117 | */ |
| 118 | 118 | private function getOrmCacheFactoryFilesystemDefinition(Container $container): callable |
| 119 | 119 | { |
| 120 | - return $container->protect(function (array $options) { |
|
| 120 | + return $container->protect(function(array $options) { |
|
| 121 | 121 | if (empty($options['path'])) { |
| 122 | 122 | throw new \RuntimeException('FilesystemCache path not defined'); |
| 123 | 123 | } |
@@ -138,7 +138,7 @@ discard block |
||
| 138 | 138 | */ |
| 139 | 139 | private function getOrmCacheFactoryMemcachedDefinition(Container $container): callable |
| 140 | 140 | { |
| 141 | - return $container->protect(function (array $options) use ($container) { |
|
| 141 | + return $container->protect(function(array $options) use ($container) { |
|
| 142 | 142 | if (empty($options['host']) || empty($options['port'])) { |
| 143 | 143 | throw new \RuntimeException('Host and port options need to be specified for memcached cache'); |
| 144 | 144 | } |
@@ -160,7 +160,7 @@ discard block |
||
| 160 | 160 | */ |
| 161 | 161 | private function getOrmCacheFactoryRedisDefinition(Container $container): callable |
| 162 | 162 | { |
| 163 | - return $container->protect(function (array $options) use ($container) { |
|
| 163 | + return $container->protect(function(array $options) use ($container) { |
|
| 164 | 164 | if (empty($options['host']) || empty($options['port'])) { |
| 165 | 165 | throw new \RuntimeException('Host and port options need to be specified for redis cache'); |
| 166 | 166 | } |
@@ -186,7 +186,7 @@ discard block |
||
| 186 | 186 | */ |
| 187 | 187 | private function getOrmCacheFactoryXCacheDefinition(Container $container): callable |
| 188 | 188 | { |
| 189 | - return $container->protect(function () use ($container) { |
|
| 189 | + return $container->protect(function() use ($container) { |
|
| 190 | 190 | return new XcacheCache(); |
| 191 | 191 | }); |
| 192 | 192 | } |