function ConditionInterface::conditionGroupFactory

Same name in other branches
  1. 9 core/lib/Drupal/Core/Database/Query/ConditionInterface.php \Drupal\Core\Database\Query\ConditionInterface::conditionGroupFactory()
  2. 8.9.x core/lib/Drupal/Core/Database/Query/ConditionInterface.php \Drupal\Core\Database\Query\ConditionInterface::conditionGroupFactory()
  3. 11.x core/lib/Drupal/Core/Database/Query/ConditionInterface.php \Drupal\Core\Database\Query\ConditionInterface::conditionGroupFactory()

Creates an object holding a group of conditions.

See andConditionGroup() and orConditionGroup() for more.

Parameters

$conjunction:

  • AND (default): this is the equivalent of andConditionGroup().
  • OR: this is the equivalent of orConditionGroup().

Return value

\Drupal\Core\Database\Query\ConditionInterface An object holding a group of conditions.

2 methods override ConditionInterface::conditionGroupFactory()
Condition::conditionGroupFactory in core/lib/Drupal/Core/Database/Query/Condition.php
Creates an object holding a group of conditions.
SelectExtender::conditionGroupFactory in core/lib/Drupal/Core/Database/Query/SelectExtender.php
Creates an object holding a group of conditions.

File

core/lib/Drupal/Core/Database/Query/ConditionInterface.php, line 212

Class

ConditionInterface
Interface for a conditional clause in a query.

Namespace

Drupal\Core\Database\Query

Code

public function conditionGroupFactory($conjunction = 'AND');

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.