public static function Drupal::entityQueryAggregate in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/lib/Drupal.php \Drupal::entityQueryAggregate()
Returns the entity query aggregate object for this entity type.
Parameters
string $entity_type: The entity type, e.g. node, for which the query object should be returned.
string $conjunction: AND if all conditions in the query need to apply, OR if any of them is enough. Optional, defaults to AND.
Return value
\Drupal\Core\Entity\Query\QueryAggregateInterface The query object that can query the given entity type.
1 call to Drupal::entityQueryAggregate()
- DrupalTest::testEntityQueryAggregate in core/
tests/ Drupal/ Tests/ Core/ DrupalTest.php - Tests the entityQueryAggregate() method.
File
- core/
lib/ Drupal.php, line 452 - Contains \Drupal.
Class
- Drupal
- Static Service Container wrapper.
Code
public static function entityQueryAggregate($entity_type, $conjunction = 'AND') {
return static::getContainer()
->get('entity.query')
->getAggregate($entity_type, $conjunction);
}