function QueryBase::__clone
Same name and namespace in other branches
- 11.x core/lib/Drupal/Core/Entity/Query/QueryBase.php \Drupal\Core\Entity\Query\QueryBase::__clone()
- 10 core/lib/Drupal/Core/Entity/Query/QueryBase.php \Drupal\Core\Entity\Query\QueryBase::__clone()
- 9 core/lib/Drupal/Core/Entity/Query/QueryBase.php \Drupal\Core\Entity\Query\QueryBase::__clone()
- 8.9.x core/lib/Drupal/Core/Entity/Query/QueryBase.php \Drupal\Core\Entity\Query\QueryBase::__clone()
Makes sure that condition objects are cloned as well.
1 call to QueryBase::__clone()
- Query::__clone in core/
lib/ Drupal/ Core/ Entity/ Query/ Sql/ Query.php - Resets cached SQL query state and re-parents conditions on clone.
1 method overrides QueryBase::__clone()
- Query::__clone in core/
lib/ Drupal/ Core/ Entity/ Query/ Sql/ Query.php - Resets cached SQL query state and re-parents conditions on clone.
File
-
core/
lib/ Drupal/ Core/ Entity/ Query/ QueryBase.php, line 348
Class
- QueryBase
- The base entity query class.
Namespace
Drupal\Core\Entity\QueryCode
public function __clone() {
$this->condition = clone $this->condition;
if (isset($this->conditionAggregate)) {
$this->conditionAggregate = clone $this->conditionAggregate;
}
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.