4
4
5
5
use OldSound \RabbitMqBundle \RabbitMq \ConsumerInterface ;
6
6
use OldSound \RabbitMqBundle \RabbitMq \ProducerInterface ;
7
+ use Symfony \Component \Config \Definition \ConfigurationInterface ;
7
8
use Symfony \Component \Config \Definition \Exception \InvalidConfigurationException ;
8
9
use Symfony \Component \Config \FileLocator ;
9
10
use Symfony \Component \DependencyInjection \ContainerBuilder ;
@@ -71,7 +72,7 @@ public function load(array $configs, ContainerBuilder $container)
71
72
}
72
73
}
73
74
74
- public function getConfiguration (array $ config , ContainerBuilder $ container )
75
+ public function getConfiguration (array $ config , ContainerBuilder $ container ): ? ConfigurationInterface
75
76
{
76
77
return new Configuration ($ this ->getAlias ());
77
78
}
@@ -531,7 +532,7 @@ protected function loadAnonConsumers()
531
532
*
532
533
* @return array
533
534
*/
534
- private function normalizeArgumentKeys (array $ config )
535
+ private function normalizeArgumentKeys (array $ config ): array
535
536
{
536
537
if (isset ($ config ['arguments ' ])) {
537
538
$ arguments = $ config ['arguments ' ];
@@ -559,7 +560,7 @@ private function normalizeArgumentKeys(array $config)
559
560
* @param string $arguments
560
561
* @return array
561
562
*/
562
- private function argumentsStringAsArray ($ arguments )
563
+ private function argumentsStringAsArray ($ arguments ): array
563
564
{
564
565
$ argumentsArray = array ();
565
566
@@ -654,7 +655,7 @@ protected function injectConnection(Definition $definition, $connectionName)
654
655
$ definition ->addArgument (new Reference (sprintf ('old_sound_rabbit_mq.connection.%s ' , $ connectionName )));
655
656
}
656
657
657
- public function getAlias () : string
658
+ public function getAlias (): string
658
659
{
659
660
return 'old_sound_rabbit_mq ' ;
660
661
}
@@ -664,6 +665,7 @@ public function getAlias() : string
664
665
*
665
666
* @param string $callback
666
667
* @param string $name
668
+ * @throws \ReflectionException
667
669
*/
668
670
protected function addDequeuerAwareCall ($ callback , $ name )
669
671
{
@@ -691,7 +693,7 @@ private function injectLogger(Definition $definition)
691
693
*
692
694
* @return array
693
695
*/
694
- protected function getDefaultExchangeOptions ()
696
+ protected function getDefaultExchangeOptions (): array
695
697
{
696
698
return array (
697
699
'name ' => '' ,
@@ -706,7 +708,7 @@ protected function getDefaultExchangeOptions()
706
708
*
707
709
* @return array
708
710
*/
709
- protected function getDefaultQueueOptions ()
711
+ protected function getDefaultQueueOptions (): array
710
712
{
711
713
return array (
712
714
'name ' => '' ,
0 commit comments