Conditions | 3 |
Paths | 3 |
Total Lines | 14 |
Code Lines | 7 |
Lines | 0 |
Ratio | 0 % |
Tests | 7 |
CRAP Score | 3.0175 |
Changes | 0 |
1 | <?php |
||
35 | 1396 | public function __construct($file, TypeParserInterface $typeParser = null) |
|
36 | { |
||
37 | 1396 | parent::__construct($typeParser); |
|
38 | |||
39 | 1396 | if (!is_file($file)) { |
|
40 | 24 | throw new \InvalidArgumentException(sprintf('The file "%s" does not exist.', $file)); |
|
41 | } |
||
42 | |||
43 | 1396 | if (!is_readable($file)) { |
|
44 | throw new \InvalidArgumentException(sprintf('The file "%s" is not readable.', $file)); |
||
45 | } |
||
46 | |||
47 | 1396 | $this->file = $file; |
|
48 | 1396 | } |
|
49 | |||
83 |