public EntityStorageBase::getAggregateQuery($conjunction = 'AND')
Gets an aggregated query instance.
Parameters
string $conjunction: (optional) The logical operator for the query, either:
- AND: all of the conditions on the query need to match.
- OR: at least one of the conditions on the query need to match.
Return value
\Drupal\Core\Entity\Query\QueryAggregateInterface The aggregated query object that can query the given entity type.
Overrides EntityStorageInterface::getAggregateQuery
See also
\Drupal\Core\Entity\EntityStorageBase::getQueryServiceName()
File
- core/lib/Drupal/Core/Entity/EntityStorageBase.php, line 519
Class
- EntityStorageBase
- A base entity storage class.
Namespace
Drupal\Core\Entity
Code
public function getAggregateQuery($conjunction = 'AND') { // Access the service directly rather than entity.query factory so the // storage's current entity type is used. return \Drupal::service($this->getQueryServiceName())->getAggregate($this->entityType, $conjunction); }
Please login to continue.