@@ -264,6 +264,9 @@ |
||
| 264 | 264 | } |
| 265 | 265 | } |
| 266 | 266 | |
| 267 | + /** |
|
| 268 | + * @param string|null $className |
|
| 269 | + */ |
|
| 267 | 270 | protected function buildArgumentsArray($serviceId, $scope, $className, array $tagAttributes = array()) |
| 268 | 271 | { |
| 269 | 272 | $arguments = array($serviceId); |
@@ -215,12 +215,12 @@ discard block |
||
| 215 | 215 | } |
| 216 | 216 | } |
| 217 | 217 | $format = '%-'.$maxName.'s '; |
| 218 | - $format .= implode("", array_map(function ($length) { return "%-{$length}s "; }, $maxTags)); |
|
| 218 | + $format .= implode("", array_map(function($length) { return "%-{$length}s "; }, $maxTags)); |
|
| 219 | 219 | $format .= '%-'.$maxScope.'s %s'; |
| 220 | 220 | |
| 221 | 221 | // the title field needs extra space to make up for comment tags |
| 222 | 222 | $format1 = '%-'.($maxName + 19).'s '; |
| 223 | - $format1 .= implode("", array_map(function ($length) { return '%-'.($length + 19).'s '; }, $maxTags)); |
|
| 223 | + $format1 .= implode("", array_map(function($length) { return '%-'.($length + 19).'s '; }, $maxTags)); |
|
| 224 | 224 | $format1 .= '%-'.($maxScope + 19).'s %s'; |
| 225 | 225 | |
| 226 | 226 | $tags = array(); |
@@ -296,7 +296,7 @@ discard block |
||
| 296 | 296 | $output->writeln('<comment>Tags</comment>'); |
| 297 | 297 | foreach ($tags as $tagName => $tagData) { |
| 298 | 298 | foreach ($tagData as $singleTagData) { |
| 299 | - $output->writeln(sprintf(' - %-30s (%s)', $tagName, implode(', ', array_map(function ($key, $value) { |
|
| 299 | + $output->writeln(sprintf(' - %-30s (%s)', $tagName, implode(', ', array_map(function($key, $value) { |
|
| 300 | 300 | return sprintf('<info>%s</info>: %s', $key, $value); |
| 301 | 301 | }, array_keys($singleTagData), array_values($singleTagData))))); |
| 302 | 302 | } |
@@ -28,6 +28,8 @@ |
||
| 28 | 28 | |
| 29 | 29 | /** |
| 30 | 30 | * {@inheritdoc} |
| 31 | + * @param boolean $debug |
|
| 32 | + * @param string $projectDir |
|
| 31 | 33 | */ |
| 32 | 34 | public function __construct($environment, $debug, $projectDir = null) |
| 33 | 35 | { |
@@ -37,7 +37,7 @@ |
||
| 37 | 37 | * Get an instance of the Configuration() class from the given file. |
| 38 | 38 | * |
| 39 | 39 | * @param string $configFile |
| 40 | - * @return YamlFileConfigurationBuilder |
|
| 40 | + * @return \Dflydev\DotAccessConfiguration\ConfigurationInterface |
|
| 41 | 41 | */ |
| 42 | 42 | private function getConfigFile($configFile) |
| 43 | 43 | { |
@@ -52,7 +52,7 @@ |
||
| 52 | 52 | } |
| 53 | 53 | |
| 54 | 54 | foreach ($data as $type => $extensions) { |
| 55 | - $data[$type] = array_filter($extensions, function ($var) { |
|
| 55 | + $data[$type] = array_filter($extensions, function($var) { |
|
| 56 | 56 | return strlen($var) > 0; |
| 57 | 57 | }); |
| 58 | 58 | } |
@@ -49,7 +49,7 @@ discard block |
||
| 49 | 49 | |
| 50 | 50 | if ($container->hasParameter($parameter)) { |
| 51 | 51 | $value = $container->getParameter($parameter); |
| 52 | - if (! is_array($value)) { |
|
| 52 | + if (!is_array($value)) { |
|
| 53 | 53 | $value = array($value); |
| 54 | 54 | } |
| 55 | 55 | |
@@ -68,7 +68,7 @@ discard block |
||
| 68 | 68 | $matcher = $this->matcher; |
| 69 | 69 | |
| 70 | 70 | return array_map( |
| 71 | - function ($path) use ($matcher) { |
|
| 71 | + function($path) use ($matcher) { |
|
| 72 | 72 | if ($matcher->isPattern($path)) { |
| 73 | 73 | return $path; |
| 74 | 74 | } |
@@ -90,7 +90,7 @@ |
||
| 90 | 90 | ); |
| 91 | 91 | |
| 92 | 92 | if ($watch) { |
| 93 | - $httpServer->addPeriodicTimer(1, function () use ($sculpin, $dataSource, $sourceSet, $consoleIo) { |
|
| 93 | + $httpServer->addPeriodicTimer(1, function() use ($sculpin, $dataSource, $sourceSet, $consoleIo) { |
|
| 94 | 94 | clearstatcache(); |
| 95 | 95 | $sourceSet->reset(); |
| 96 | 96 | |
@@ -50,7 +50,7 @@ |
||
| 50 | 50 | $this->loop = new StreamSelectLoop; |
| 51 | 51 | $socketServer = new ReactSocketServer($this->loop); |
| 52 | 52 | $httpServer = new ReactHttpServer($socketServer); |
| 53 | - $httpServer->on("request", function ($request, $response) use ($repository, $docroot, $output) { |
|
| 53 | + $httpServer->on("request", function($request, $response) use ($repository, $docroot, $output) { |
|
| 54 | 54 | $path = $docroot.'/'.ltrim(rawurldecode($request->getPath()), '/'); |
| 55 | 55 | if (is_dir($path)) { |
| 56 | 56 | $path .= '/index.html'; |
@@ -37,7 +37,7 @@ discard block |
||
| 37 | 37 | $container->setParameter(self::generateId('types'), array_keys($config)); |
| 38 | 38 | |
| 39 | 39 | foreach ($config as $type => $setup) { |
| 40 | - if (! $setup['enabled']) { |
|
| 40 | + if (!$setup['enabled']) { |
|
| 41 | 41 | // We can skip any types that are not enabled. |
| 42 | 42 | continue; |
| 43 | 43 | } |
@@ -49,7 +49,7 @@ discard block |
||
| 49 | 49 | $detectionTypes = is_array($setup['type']) ? $setup['type'] : array($setup['type']); |
| 50 | 50 | |
| 51 | 51 | $itemClassId = self::generateTypesId($type, 'item.class'); |
| 52 | - if (! $container->hasParameter($itemClassId)) { |
|
| 52 | + if (!$container->hasParameter($itemClassId)) { |
|
| 53 | 53 | $container->setParameter($itemClassId, 'Sculpin\Contrib\ProxySourceCollection\ProxySourceItem'); |
| 54 | 54 | } |
| 55 | 55 | |
@@ -59,7 +59,7 @@ discard block |
||
| 59 | 59 | |
| 60 | 60 | $collectionSorterId = self::generateTypesId($type, 'collection.sorter'); |
| 61 | 61 | |
| 62 | - if (! $container->hasDefinition($collectionSorterId)) { |
|
| 62 | + if (!$container->hasDefinition($collectionSorterId)) { |
|
| 63 | 63 | $collectionSorter = new Definition('Sculpin\Contrib\ProxySourceCollection\Sorter\DefaultSorter'); |
| 64 | 64 | $container->setDefinition($collectionSorterId, $collectionSorter); |
| 65 | 65 | } |
@@ -45,7 +45,7 @@ discard block |
||
| 45 | 45 | // Default case is we want the user to specify just one |
| 46 | 46 | // path but we can allow for multiple if they want to. |
| 47 | 47 | ->ifString() |
| 48 | - ->then(function ($v) { return array($v); }) |
|
| 48 | + ->then(function($v) { return array($v); }) |
|
| 49 | 49 | ->end() |
| 50 | 50 | ->prototype('scalar')->end() |
| 51 | 51 | ->end() |
@@ -59,12 +59,12 @@ discard block |
||
| 59 | 59 | // Default case is we want the user to specify just one |
| 60 | 60 | // taxonomy but we can allow for multiple if they want to. |
| 61 | 61 | ->ifString() |
| 62 | - ->then(function ($v) { return array(array('name' => $v)); }) |
|
| 62 | + ->then(function($v) { return array(array('name' => $v)); }) |
|
| 63 | 63 | ->end() |
| 64 | 64 | ->prototype('array') |
| 65 | 65 | ->beforeNormalization() |
| 66 | 66 | ->ifString() |
| 67 | - ->then(function ($v) { return array('name' => $v); }) |
|
| 67 | + ->then(function($v) { return array('name' => $v); }) |
|
| 68 | 68 | ->end() |
| 69 | 69 | ->children() |
| 70 | 70 | ->scalarNode('name')->end() |
@@ -22,8 +22,8 @@ |
||
| 22 | 22 | class Configuration implements ConfigurationInterface |
| 23 | 23 | { |
| 24 | 24 | /** |
| 25 | - * {@inheritdoc} |
|
| 26 | - */ |
|
| 25 | + * {@inheritdoc} |
|
| 26 | + */ |
|
| 27 | 27 | public function getConfigTreeBuilder() |
| 28 | 28 | { |
| 29 | 29 | $treeBuilder = new TreeBuilder; |