public function onXmlFile(string $xmlFile, bool $xinclude = true): self
    {
        $doc = new \DOMDocument();
        if (false === @$doc->load($xmlFile)) {
            throw new XslProcessorException(
                    'Can not read xml document file ' . $xmlFile
            );
        }

        if (true === $xinclude) {
            $doc->xinclude();
        }

        return $this->onDocument($doc);
    }
public function onXmlFile(string $xmlFile, bool $xinclude = true): self
    {
        $doc = new \DOMDocument();
        if (false === @$doc->load($xmlFile)) {
            throw new XslProcessorException(
                    'Can not read xml document file ' . $xmlFile
            );
        }

        if (true === $xinclude) {
            $doc->xinclude();
        }

        return $this->onDocument($doc);
    }
public function onXmlFile ( string $ xmlFile , bool $ xinclude = true ) : self { $ doc = new \ DOMDocument ( ) ; if ( false === @ $ doc -> load ( $ xmlFile ) ) { throw new XslProcessorException ( 'Can not read xml document file ' . $ xmlFile ) ; } if ( true === $ xinclude ) { $ doc -> xinclude ( ) ; } return $ this -> onDocument ( $ doc ) ; }
sets the document to transform

@param   string  $xmlFile   name of the xml file containing the document to transform
@param   bool    $xinclude  whether to resolve xincludes or not, defaults to true
@return  \stubbles\xml\xsl\XslProcessor
@throws  \stubbles\xml\xsl\XslProcessorException
sets the document to transform