Passed
Push — master ( d8dce2...145ba7 )
by Panagiotis
02:43
created

EventHandlerAlreadyExists   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 17
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
wmc 1
eloc 5
dl 0
loc 17
c 0
b 0
f 0
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 5 1
1
<?php
2
3
declare(strict_types=1);
4
5
/**
6
 * Author: panosru
7
 * Date: 23/04/2018
8
 * Time: 21:26
9
 */
10
11
namespace Omega\FaultManager\Exceptions;
12
13
use Omega\FaultManager\Abstracts\FaultManagerException as AFaultManagerException;
14
15
/**
16
 * Class EventHandlerAlreadyExists
17
 * @package Omega\FaultManager\Exceptions
18
 */
19
class EventHandlerAlreadyExists extends AFaultManagerException
20
{
21
    /** @var int */
22
    protected $code = 66006;
23
24
    /** @var string */
25
    protected $message = 'A handler for "%s" already exists.';
26
27
    /**
28
     * EventHandlerAlreadyExists constructor.
29
     * @param string $eventHandler
30
     */
31
    public function __construct(string $eventHandler)
32
    {
33
        $this->arguments[] = $eventHandler;
34
35
        parent::__construct();
36
    }
37
}
38