Lines Matching defs:children
136 public $children = array();
164 $this->children = null;
228 $string .= ' children: ' . count($this->children);
245 // children list first.
249 $this->parent->children[] = $this;
257 return !empty($this->children);
260 function children($idx = -1)
263 return $this->children;
266 if (isset($this->children[$idx])) {
267 return $this->children[$idx];
275 if (count($this->children) > 0) {
276 return $this->children[0];
283 if (count($this->children) > 0) {
284 return end($this->children);
295 $idx = array_search($this, $this->parent->children, true);
297 if ($idx !== false && isset($this->parent->children[$idx + 1])) {
298 return $this->parent->children[$idx + 1];
310 $idx = array_search($this, $this->parent->children, true);
313 return $this->parent->children[$idx - 1];
592 $nodes = $this->children;
595 && in_array($this, $this->parent->children)) { // Next-Sibling Combinator
596 $index = array_search($this, $this->parent->children, true) + 1;
597 if ($index < count($this->parent->children))
598 $nodes[] = $this->parent->children[$index];
601 && in_array($this, $this->parent->children)) { // Subsequent Sibling Combinator
602 $index = array_search($this, $this->parent->children, true);
603 $nodes = array_slice($this->parent->children, $index);
618 if($pass && !in_array($node, $node->parent->children, true)) {
689 foreach ($node->parent->children as $c) {
1290 $cidx = array_search($node, $this->children, true);
1295 foreach($node->children as $child) {
1310 unset($this->children[$cidx]);
1345 return $this->children($idx);
1595 if (isset($this->children)) {
1596 foreach ($this->children as $n) {
2136 $this->parent->children[] = $node;