Completed
Branch master (7d7b3f)
by Ori
01:38
created

__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 3
nc 1
nop 1
dl 0
loc 5
rs 9.4285
c 0
b 0
f 0
1
<?php
2
3
namespace frictionlessdata\datapackage\Exceptions;
4
5
use frictionlessdata\datapackage\Validators\DatapackageValidationError;
6
7
class DatapackageValidationFailedException extends \Exception
8
{
9
    public $validationErrors;
10
11
    public function __construct($validationErrors)
12
    {
13
        $this->validationErrors = $validationErrors;
14
        parent::__construct('Datapackage validation failed: '.DatapackageValidationError::getErrorMessages($validationErrors));
15
    }
16
}
17