ReturnByReferenceException::__construct()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 7

Duplication

Lines 7
Ratio 100 %

Importance

Changes 0
Metric Value
dl 7
loc 7
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 3
1
<?php
2
3
/*
4
 * This file is part of the Prophecy.
5
 * (c) Konstantin Kudryashov <[email protected]>
6
 *     Marcello Duarte <[email protected]>
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
namespace Prophecy\Exception\Doubler;
13
14 View Code Duplication
class ReturnByReferenceException extends DoubleException
0 ignored issues
show
Duplication introduced by
This class seems to be duplicated in your project.

Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.

You can also find more detailed suggestions in the “Code” section of your repository.

Loading history...
15
{
16
    private $classname;
17
    private $methodName;
18
19
    /**
20
     * @param string $message
21
     * @param string $classname
22
     * @param string $methodName
23
     */
24
    public function __construct($message, $classname, $methodName)
25
    {
26
        parent::__construct($message);
27
28
        $this->classname  = $classname;
29
        $this->methodName = $methodName;
30
    }
31
32
    public function getClassname()
33
    {
34
        return $this->classname;
35
    }
36
37
    public function getMethodName()
38
    {
39
        return $this->methodName;
40
    }
41
}
42