function Query::__construct

Same name in this branch
  1. 8.x drupal/core/lib/Drupal/Core/Database/Query/Query.php \Drupal\Core\Database\Query\Query::__construct()
  2. 8.x drupal/core/lib/Drupal/Core/Config/Entity/Query/Query.php \Drupal\Core\Config\Entity\Query\Query::__construct()
  3. 8.x drupal/core/modules/field_sql_storage/lib/Drupal/field_sql_storage/Entity/Query.php \Drupal\field_sql_storage\Entity\Query::__construct()

Constructs a Query object.

Parameters

string $entity_type: The entity type.

string $conjunction:

  • AND: all of the conditions on the query need to match.
  • OR: at least one of the conditions on the query need to match.

\Drupal\Core\Entity\EntityManager $entity_manager: The entity manager that stores all meta information.

\Drupal\Core\Config\StorageInterface $config_storage: The actual config storage which is used to list all config items.

Overrides QueryBase::__construct

File

drupal/core/lib/Drupal/Core/Config/Entity/Query/Query.php, line 48
Contains \Drupal\Core\Config\Entity\Query\Query.

Class

Query
Defines the entity query for configuration entities.

Namespace

Drupal\Core\Config\Entity\Query

Code

function __construct($entity_type, $conjunction, EntityManager $entity_manager, StorageInterface $config_storage) {
  parent::__construct($entity_type, $conjunction);
  $this->entityManager = $entity_manager;
  $this->configStorage = $config_storage;
}