30 if ($keys == array_keys($keys)) {
61 $this->whitespace =
false;
64 if (empty($children)) {
74 $pcdata_allowed = isset($this->elements[
'#PCDATA']);
77 $all_whitespace =
true;
79 $stack = array_reverse($children);
80 while (!empty($stack)) {
81 $node = array_pop($stack);
82 if (!empty($node->is_whitespace)) {
86 $all_whitespace =
false;
88 if (!isset($this->elements[$node->name])) {
98 for ($i = count($node->children) - 1; $i >= 0; $i--) {
99 $stack[] = $node->children[$i];
110 if ($all_whitespace) {
111 $this->whitespace =
true;
Concrete element node class.
Definition that allows a set of elements, but disallows empty children.
Defines allowed child nodes and validates nodes against it.
$whitespace
Whether or not the last passed node was all whitespace.
Create styles array
The data for the language used.
Concrete text token class.
validateChildren($children, $config, $context)
$elements
Lookup table of allowed elements.