ResponderAwareTrait   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 15
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 0

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 15
wmc 1
lcom 1
cbo 0
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A addResponder() 0 4 1
1
<?php
2
/**
3
 * (c) Tomasz Kunicki <[email protected]>
4
 *
5
 * For the full copyright and license information, please view the LICENSE
6
 * file that was distributed with this source code.
7
 */
8
namespace Domain\Common\UseCase;
9
10
/**
11
 * Class ResponderAwareTrait
12
 *
13
 * @package Domain\Common\UseCase
14
 */
15
trait ResponderAwareTrait
16
{
17
    /**
18
     * @var ResponderInterface[]
19
     */
20
    private $responders = [];
21
22
    /**
23
     * @param ResponderInterface $responder
24
     */
25
    public function addResponder(ResponderInterface $responder)
26
    {
27
        $this->responders[] = $responder;
28
    }
29
}