Code Coverage |
||||||||||
Lines |
Functions and Methods |
Classes and Traits |
||||||||
| Total | |
100.00% |
1 / 1 |
|
100.00% |
1 / 1 |
CRAP | |
100.00% |
1 / 1 |
| ConformanceMode | |
100.00% |
1 / 1 |
|
100.00% |
1 / 1 |
1 | |
100.00% |
1 / 1 |
| __construct | |
100.00% |
1 / 1 |
|
100.00% |
1 / 1 |
1 | |||
| 1 | <?php |
| 2 | |
| 3 | declare(strict_types=1); |
| 4 | |
| 5 | namespace Phpdftk\Pdf\Conformance; |
| 6 | |
| 7 | use Phpdftk\Pdf\Conformance\Profile\ConformanceProfile; |
| 8 | |
| 9 | /** |
| 10 | * Value object holding the active conformance profile(s) and behavior mode. |
| 11 | */ |
| 12 | final readonly class ConformanceMode |
| 13 | { |
| 14 | /** @var list<ConformanceProfile> */ |
| 15 | public array $profiles; |
| 16 | |
| 17 | /** |
| 18 | * @param ConformanceProfile[] $profiles |
| 19 | * @param bool $strict If true, throw on ERROR violations at generate() time |
| 20 | */ |
| 21 | public function __construct( |
| 22 | array $profiles, |
| 23 | public bool $strict = true, |
| 24 | ) { |
| 25 | $this->profiles = array_values($profiles); |
| 26 | } |
| 27 | } |