Passed
Push — master ( 18af30...0e6a78 )
by Mathias
45:31 queued 28:39
created

MongoQueueControllerFactory   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 11
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 1
eloc 5
dl 0
loc 11
ccs 5
cts 5
cp 1
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A __invoke() 0 8 1
1
<?php
2
/**
3
 * YAWIK
4
 *
5
 * @filesource
6
 * @license MIT
7
 * @copyright  2013 - 2019 Cross Solution <http://cross-solution.de>
8
 */
9
  
10
/** */
11
namespace Core\Queue\Controller;
12
13
use Core\Queue\Worker\MongoWorker;
14
use Interop\Container\ContainerInterface;
15
use SlmQueue\Queue\QueuePluginManager;
16
use Zend\ServiceManager\Factory\FactoryInterface;
17
18
/**
19
 * Factory for \Core\Queue\Controller\MongoQueueController
20
 * 
21
 * @author Mathias Gelhausen <[email protected]>
22
 */
23
class MongoQueueControllerFactory implements FactoryInterface
24
{
25
    
26 1
    public function __invoke(ContainerInterface $container, $requestedName, array $options = null)
27
    {
28 1
        $service = new MongoQueueController(
29 1
            $container->get(MongoWorker::class),
30 1
            $container->get(QueuePluginManager::class)
31
        );
32
        
33 1
        return $service;    
34
    }
35
}
36