| Total Complexity | 3 |
| Total Lines | 31 |
| Duplicated Lines | 0 % |
| Coverage | 100% |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 12 | class XmlCheckSchemaSubscriber extends AbstractCheckSchemaSubscriber implements EventSubscriberInterface |
||
| 13 | { |
||
| 14 | /** |
||
| 15 | * @var XmlSchemaValidatorFactory |
||
| 16 | */ |
||
| 17 | protected $xmlSchemaValidatorFactory; |
||
| 18 | |||
| 19 | /** |
||
| 20 | * @param XmlSchemaValidatorFactory $xmlSchemaValidatorFactory |
||
| 21 | */ |
||
| 22 | 2 | public function __construct(XmlSchemaValidatorFactory $xmlSchemaValidatorFactory) |
|
| 23 | { |
||
| 24 | 2 | $this->xmlSchemaValidatorFactory = $xmlSchemaValidatorFactory; |
|
| 25 | 2 | } |
|
| 26 | |||
| 27 | /** |
||
| 28 | * {@inheritdoc} |
||
| 29 | */ |
||
| 30 | 8 | public static function getSubscribedEvents(): array |
|
| 31 | { |
||
| 32 | return [ |
||
| 33 | 8 | Events::getCheckSchemaEventNameFor('xml') => 'validateSchema', |
|
| 34 | ]; |
||
| 35 | } |
||
| 36 | |||
| 37 | /** |
||
| 38 | * {@inheritdoc} |
||
| 39 | */ |
||
| 40 | 2 | protected function getSchemaValidatorFactory(): SchemaValidatorFactoryInterface |
|
| 43 | } |
||
| 44 | } |
||
| 45 |