Lines Matching refs:parent

132 	public $parent = null;  variable in imapmarkers\\simple_html_dom_node
153 $this->parent = null;
229 function parent($parent = null) { argument
233 if ($parent !== null) {
234 $this->parent = $parent;
235 $this->parent->nodes[] = $this;
236 $this->parent->children[] = $this;
239 return $this->parent;
273 if ($this->parent === null) {
277 $idx = array_search($this, $this->parent->children, true);
279 if ($idx !== false && isset($this->parent->children[$idx + 1])) {
280 return $this->parent->children[$idx + 1];
287 if ($this->parent === null) {
291 $idx = array_search($this, $this->parent->children, true);
294 return $this->parent->children[$idx - 1];
306 if ($this->parent === null) {
310 $ancestor = $this->parent;
321 $ancestor = $ancestor->parent;
578 $parent = $this->parent;
579 while (!isset($parent->_[HDOM_INFO_END]) && $parent !== null) {
581 $parent = $parent->parent;
583 $end += $parent->_[HDOM_INFO_END];
593 && $this->parent
594 && in_array($this, $this->parent->children)) { // Next-Sibling Combinator
595 $index = array_search($this, $this->parent->children, true) + 1;
596 if ($index < count($this->parent->children))
597 $nodes[] = $this->parent->children[$index];
599 && $this->parent
600 && in_array($this, $this->parent->children)) { // Subsequent Sibling Combinator
601 $index = array_search($this, $this->parent->children, true);
602 $nodes = array_slice($this->parent->children, $index);
612 if (!$node->parent) {
624 if ($pass && !in_array($node, $node->parent->children, true)) {
697 foreach ($node->parent->children as $c) {
1318 if ($this->parent) {
1319 $this->parent->removeChild($this);
1370 return $this->parent();
1402 $node->parent($this);
1421 protected $parent; variable in imapmarkers\\simple_html_dom
1616 if (isset($this->parent)) {
1617 $this->parent->clear();
1618 unset($this->parent);
1654 $this->parent = $this->root;
1840 $parent_lower = strtolower($this->parent->tag);
1851 $this->parent->_[HDOM_INFO_END] = 0;
1852 $org_parent = $this->parent;
1856 while (($this->parent->parent)
1857 && strtolower($this->parent->tag) !== $tag_lower
1859 $this->parent = $this->parent->parent;
1863 if (strtolower($this->parent->tag) !== $tag_lower) {
1864 $this->parent = $org_parent; // restore origonal parent
1866 if ($this->parent->parent) {
1867 $this->parent = $this->parent->parent;
1870 $this->parent->_[HDOM_INFO_END] = $this->cursor;
1873 } elseif (($this->parent->parent)
1878 $this->parent->_[HDOM_INFO_END] = 0; // No end tag
1879 $org_parent = $this->parent;
1883 while (($this->parent->parent)
1884 && strtolower($this->parent->tag) !== $tag_lower
1886 $this->parent = $this->parent->parent;
1890 if (strtolower($this->parent->tag) !== $tag_lower) {
1891 $this->parent = $org_parent; // restore origonal parent
1892 $this->parent->_[HDOM_INFO_END] = $this->cursor;
1895 } elseif (($this->parent->parent)
1896 && strtolower($this->parent->parent->tag) === $tag_lower
1898 $this->parent->_[HDOM_INFO_END] = 0;
1899 $this->parent = $this->parent->parent;
1906 $this->parent->_[HDOM_INFO_END] = $this->cursor;
1908 if ($this->parent->parent) {
1909 $this->parent = $this->parent->parent;
1984 while (isset($this->optional_closing_tags[$tag_lower][strtolower($this->parent->tag)])) {
1985 $this->parent->_[HDOM_INFO_END] = 0;
1986 $this->parent = $this->parent->parent;
1988 $node->parent = $this->parent;
2086 $this->parent = $node;
2146 $node->parent = $this->parent;
2147 $this->parent->nodes[] = $node;
2149 $this->parent->children[] = $node;