UndefinedTargetClassException::__construct()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 1
c 1
b 0
f 0
dl 0
loc 3
rs 10
cc 1
nc 1
nop 2
1
<?php
2
/**
3
 * UndefinedTargetClassException
4
 *
5
 * @package php-deferred-callchain
6
 * @author  Jean Claveau
7
 */
8
namespace JClaveau\Async\Exceptions;
9
use       JClaveau\Async\DeferredCallChain;
10
use       LogicException;
11
12
/**
13
 * Thrown when defining an expected target which is not an existing class,
14
 * an existing interface or native type.
15
 */
16
class UndefinedTargetClassException extends LogicException
17
{
18
    /**
19
     * Constructor.
20
     * 
21
     * @param DeferredCallChain $callchain
22
     * @param mixed             $expected_target The wrong expected target
23
     */
24
    public function __construct(DeferredCallChain $callchain, $expected_target)
25
    {
26
        $this->message = "The expected target of $callchain is neither a existing class or interface nor a native type: ". $expected_target;
27
    }
28
    
29
    /**/
30
}
31