19 declare(strict_types=1);
    32         $this->df = $data_factory;
    38             'level=' . $error->level,
    39             'code=' . $error->code,
    40             'line=' . $error->line,
    41             'col=' . $error->column,
    42             'msg=' . trim($error->message)
    49         foreach ($errors as $error) {
    58         if ([] === $this->error_stack) {
    59             $this->xml_error_state = libxml_use_internal_errors(
true);
    60             libxml_clear_errors();
    65         $this->error_stack[] = [];
    70         $currentErrors = libxml_get_errors();
    71         libxml_clear_errors();
    73         $level = count($this->error_stack) - 1;
    74         $this->error_stack[$level] = array_merge($this->error_stack[$level], $currentErrors);
    84         $errors = array_pop($this->error_stack);
    86         if ([] === $this->error_stack) {
    87             libxml_use_internal_errors($this->xml_error_state);
   102             if ($xml->xpath(
'//SubType')) {
   103                 return $this->df->ok($xml);
   107             $error->level = LIBXML_ERR_FATAL;
   109             $error->message = 
'No "SubType" element found';
   115             return $this->df->error($this->
formatErrors(...$errors));
 
Interface Observer  Contains several chained tasks and infos about them. 
 
__construct(DataTypeFactory $data_factory)
 
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
 
formatError(LibXMLError $error)
 
formatErrors(LibXMLError ... $errors)