Completed
Push — master ( cc3c57...4239ab )
by Jonathan
01:51
created

PasswordMismatchException::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 11
Code Lines 9

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 11
rs 9.4285
cc 1
eloc 9
nc 1
nop 5
1
<?php
2
namespace Jsq\Iron;
3
4
use Exception;
5
use InvalidArgumentException as Iae;
6
7
class PasswordMismatchException extends Iae implements IronException
8
{
9
    private $idProvided;
10
    private $idSought;
11
12
    /**
13
     * PasswordMismatchException constructor.
14
     * @param string $idProvided
15
     * @param string $idSought
16
     * @param string $message
17
     * @param $code
18
     * @param Exception $previous
19
     */
20
    public function __construct(
21
        $idProvided,
22
        $idSought,
23
        $message = '',
24
        $code = 0,
25
        Exception $previous = null
26
    ) {
27
        $this->idProvided = $idProvided;
28
        $this->idSought = $idSought;
29
        parent::__construct($message, $code, $previous);
30
    }
31
32
    /**
33
     * @return string
34
     */
35
    public function getIdOfPasswordProvided()
36
    {
37
        return $this->idProvided;
38
    }
39
40
    /**
41
     * @return string
42
     */
43
    public function getIdOfPasswordSought()
44
    {
45
        return $this->idSought;
46
    }
47
}
48