TextNode
in package
implements
NodeInterface
FinalYes
Tags
Table of Contents
Interfaces
- NodeInterface
- Represents the sanitized version of a DOM node in the sanitized tree.
Properties
- $parentNode : NodeInterface
- $text : string
Methods
- __construct() : mixed
- addChild() : void
- Add a child node to this node.
- getParent() : NodeInterface|null
- Return the parent node of this node, or null if it has no parent node.
- render() : string
- Render this node as a string, recursively rendering its children as well.
Properties
$parentNode
private
NodeInterface
$parentNode
$text
private
string
$text
Methods
__construct()
public
__construct(NodeInterface $parentNode, string $text) : mixed
Parameters
- $parentNode : NodeInterface
- $text : string
addChild()
Add a child node to this node.
public
addChild(NodeInterface $node) : void
Parameters
- $node : NodeInterface
getParent()
Return the parent node of this node, or null if it has no parent node.
public
getParent() : NodeInterface|null
Return values
NodeInterface|nullrender()
Render this node as a string, recursively rendering its children as well.
public
render() : string