public function ConditionBase::condition in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/lib/Drupal/Core/Entity/Query/ConditionBase.php \Drupal\Core\Entity\Query\ConditionBase::condition()
Adds a condition.
Parameters
string|\Drupal\Core\Entity\Query\ConditionInterface $field:
mixed $value:
string $operator:
string $langcode:
Return value
Overrides ConditionInterface::condition
See also
\Drupal\Core\Entity\Query\QueryInterface::condition()
6 calls to ConditionBase::condition()
- Condition::exists in core/
lib/ Drupal/ Core/ Config/ Entity/ Query/ Condition.php - Queries for the existence of a field.
- Condition::exists in core/
lib/ Drupal/ Core/ Entity/ Query/ Sql/ Condition.php - Queries for the existence of a field.
- Condition::exists in core/
lib/ Drupal/ Core/ Entity/ Query/ Null/ Condition.php - Queries for the existence of a field.
- Condition::notExists in core/
lib/ Drupal/ Core/ Config/ Entity/ Query/ Condition.php - Queries for the existence of a field.
- Condition::notExists in core/
lib/ Drupal/ Core/ Entity/ Query/ Sql/ Condition.php - Queries for the existence of a field.
File
- core/
lib/ Drupal/ Core/ Entity/ Query/ ConditionBase.php, line 18 - Contains \Drupal\Core\Entity\Query\ConditionBase.
Class
- ConditionBase
- Defines a common base class for all entity condition implementations.
Namespace
Drupal\Core\Entity\QueryCode
public function condition($field, $value = NULL, $operator = NULL, $langcode = NULL) {
$this->conditions[] = array(
'field' => $field,
'value' => $value,
'operator' => $operator,
'langcode' => $langcode,
);
return $this;
}