ExistsCondition
in package
implements
ConditionInterface
Condition that represents `EXISTS` operator.
Tags
Table of Contents
Interfaces
- ConditionInterface
- Interface ConditionInterface should be implemented by classes that represent a condition in DBAL of framework.
Properties
Methods
- __construct() : mixed
- ExistsCondition constructor.
- fromArrayDefinition() : $this
- Creates object by array-definition as described in [Query Builder – Operator format](guide:db-query-builder#operator-format) guide article.
- getOperator() : string
- getQuery() : Query
Properties
$operator
private
string
$operator
the operator to use (e.g. EXISTS
or NOT EXISTS
)
$query
private
Query
$query
the [[Query]] object representing the sub-query.
Methods
__construct()
ExistsCondition constructor.
public
__construct(string $operator, Query $query) : mixed
Parameters
- $operator : string
-
the operator to use (e.g.
EXISTS
orNOT EXISTS
) - $query : Query
-
the [[Query]] object representing the sub-query.
fromArrayDefinition()
Creates object by array-definition as described in [Query Builder – Operator format](guide:db-query-builder#operator-format) guide article.
public
static fromArrayDefinition(mixed $operator, mixed $operands) : $this
Parameters
- $operator : mixed
-
operator in uppercase.
- $operands : mixed
-
array of corresponding operands
Return values
$thisgetOperator()
public
getOperator() : string
Return values
stringgetQuery()
public
getQuery() : Query