• internal This class is not covered by the backward compatibility promise for PHPUnit
CloneableFinalInstantiable
Methods
public static import(DOMElement $element) : DOMElement
public static load( $actual, bool $isHtml = false, string $filename = '', bool $xinclude = false, bool $strict = false) : DOMDocument
 

Load an $actual document into a DOMDocument. This is called
from the selector assertions.

If $actual is already a DOMDocument, it is returned with
no changes. Otherwise, $actual is loaded into a new DOMDocument
as either HTML or XML, depending on the value of $isHtml. If $isHtml is
false and $xinclude is true, xinclude is performed on the loaded
DOMDocument.

Note: prior to PHPUnit 3.3.0, this method loaded a file and
not a string as it currently does. To load a file into a
DOMDocument, use loadFile() instead.

public static loadFile(string $filename, bool $isHtml = false, bool $xinclude = false, bool $strict = false) : DOMDocument
 

Loads an XML (or HTML) file into a DOMDocument object.

public static prepareString(string $string) : string
 

Escapes a string for the use in XML documents

Any Unicode character is allowed, excluding the surrogate blocks, FFFE,
and FFFF (not even as character reference).

  • see https://www.w3.org/TR/xml/#charsets
public static removeCharacterDataNodes(DOMNode $node) : void
public static xmlToVariable(DOMElement $element)
 

"Convert" a DOMElement object into a PHP variable.

Methods
private static convertToUtf8(string $string) : string
private static isUtf8(string $string) : bool
Methods
private static convertToUtf8(string $string) : string
public static import(DOMElement $element) : DOMElement
private static isUtf8(string $string) : bool
public static load( $actual, bool $isHtml = false, string $filename = '', bool $xinclude = false, bool $strict = false) : DOMDocument
 

Load an $actual document into a DOMDocument. This is called
from the selector assertions.

If $actual is already a DOMDocument, it is returned with
no changes. Otherwise, $actual is loaded into a new DOMDocument
as either HTML or XML, depending on the value of $isHtml. If $isHtml is
false and $xinclude is true, xinclude is performed on the loaded
DOMDocument.

Note: prior to PHPUnit 3.3.0, this method loaded a file and
not a string as it currently does. To load a file into a
DOMDocument, use loadFile() instead.

public static loadFile(string $filename, bool $isHtml = false, bool $xinclude = false, bool $strict = false) : DOMDocument
 

Loads an XML (or HTML) file into a DOMDocument object.

public static prepareString(string $string) : string
 

Escapes a string for the use in XML documents

Any Unicode character is allowed, excluding the surrogate blocks, FFFE,
and FFFF (not even as character reference).

  • see https://www.w3.org/TR/xml/#charsets
public static removeCharacterDataNodes(DOMNode $node) : void
public static xmlToVariable(DOMElement $element)
 

"Convert" a DOMElement object into a PHP variable.

© 2020 Bruce Wells
Search Namespaces \ Classes
ConfigurationNumbers (0-9.) only