Zend Framework
3.0
|
Public Member Functions | |
nest () | |
Begin nesting predicates. | |
setUnnest (Predicate $predicate) | |
Indicate what predicate will be unnested. | |
unnest () | |
Indicate end of nested predicate. | |
equalTo ($left, $right, $leftType=self::TYPE_IDENTIFIER, $rightType=self::TYPE_VALUE) | |
Create "Equal To" predicate. | |
notEqualTo ($left, $right, $leftType=self::TYPE_IDENTIFIER, $rightType=self::TYPE_VALUE) | |
Create "Not Equal To" predicate. | |
lessThan ($left, $right, $leftType=self::TYPE_IDENTIFIER, $rightType=self::TYPE_VALUE) | |
Create "Less Than" predicate. | |
greaterThan ($left, $right, $leftType=self::TYPE_IDENTIFIER, $rightType=self::TYPE_VALUE) | |
Create "Greater Than" predicate. | |
lessThanOrEqualTo ($left, $right, $leftType=self::TYPE_IDENTIFIER, $rightType=self::TYPE_VALUE) | |
Create "Less Than Or Equal To" predicate. | |
greaterThanOrEqualTo ($left, $right, $leftType=self::TYPE_IDENTIFIER, $rightType=self::TYPE_VALUE) | |
Create "Greater Than Or Equal To" predicate. | |
like ($identifier, $like) | |
Create "Like" predicate. | |
notLike ($identifier, $notLike) | |
Create "notLike" predicate. | |
expression ($expression, $parameters=null) | |
Create an expression, with parameter placeholders. | |
literal ($literal) | |
Create "Literal" predicate. | |
isNull ($identifier) | |
Create "IS NULL" predicate. | |
isNotNull ($identifier) | |
Create "IS NOT NULL" predicate. | |
in ($identifier, $valueSet=null) | |
Create "IN" predicate. | |
notIn ($identifier, $valueSet=null) | |
Create "NOT IN" predicate. | |
between ($identifier, $minValue, $maxValue) | |
Create "between" predicate. | |
notBetween ($identifier, $minValue, $maxValue) | |
Create "NOT BETWEEN" predicate. | |
predicate (PredicateInterface $predicate) | |
Use given predicate directly. | |
__get ($name) | |
Overloading. | |
Public Member Functions inherited from PredicateSet | |
__construct (array $predicates=null, $defaultCombination=self::COMBINED_BY_AND) | |
Constructor. | |
addPredicate (PredicateInterface $predicate, $combination=null) | |
Add predicate to set. | |
addPredicates ($predicates, $combination=self::OP_AND) | |
Add predicates to set. | |
getPredicates () | |
Return the predicates. | |
orPredicate (PredicateInterface $predicate) | |
Add predicate using OR operator. | |
andPredicate (PredicateInterface $predicate) | |
Add predicate using AND operator. | |
count () | |
Get count of attached predicates. | |
Protected Attributes | |
$unnest = null | |
$nextPredicateCombineOperator = null | |
Protected Attributes inherited from PredicateSet | |
$defaultCombination = self::COMBINED_BY_AND | |
$predicates = [] | |
Additional Inherited Members | |
Public Attributes inherited from PredicateSet | |
const | COMBINED_BY_AND = 'AND' |
const | OP_AND = 'AND' |
const | COMBINED_BY_OR = 'OR' |
const | OP_OR = 'OR' |
__get | ( | $name | ) |
between | ( | $identifier, | |
$minValue, | |||
$maxValue | |||
) |
equalTo | ( | $left, | |
$right, | |||
$leftType = self::TYPE_IDENTIFIER , |
|||
$rightType = self::TYPE_VALUE |
|||
) |
Create "Equal To" predicate.
Utilizes Operator predicate
int | float | bool | string | $left | |
int | float | bool | string | $right | |
string | $leftType | TYPE_IDENTIFIER or TYPE_VALUE by default TYPE_IDENTIFIER { |
string | $rightType | TYPE_IDENTIFIER or TYPE_VALUE by default TYPE_VALUE { |
expression | ( | $expression, | |
$parameters = null |
|||
) |
Create an expression, with parameter placeholders.
$expression | |
$parameters |
greaterThan | ( | $left, | |
$right, | |||
$leftType = self::TYPE_IDENTIFIER , |
|||
$rightType = self::TYPE_VALUE |
|||
) |
Create "Greater Than" predicate.
Utilizes Operator predicate
int | float | bool | string | $left | |
int | float | bool | string | $right | |
string | $leftType | TYPE_IDENTIFIER or TYPE_VALUE by default TYPE_IDENTIFIER { |
string | $rightType | TYPE_IDENTIFIER or TYPE_VALUE by default TYPE_VALUE { |
greaterThanOrEqualTo | ( | $left, | |
$right, | |||
$leftType = self::TYPE_IDENTIFIER , |
|||
$rightType = self::TYPE_VALUE |
|||
) |
Create "Greater Than Or Equal To" predicate.
Utilizes Operator predicate
int | float | bool | string | $left | |
int | float | bool | string | $right | |
string | $leftType | TYPE_IDENTIFIER or TYPE_VALUE by default TYPE_IDENTIFIER { |
string | $rightType | TYPE_IDENTIFIER or TYPE_VALUE by default TYPE_VALUE { |
in | ( | $identifier, | |
$valueSet = null |
|||
) |
isNotNull | ( | $identifier | ) |
isNull | ( | $identifier | ) |
lessThan | ( | $left, | |
$right, | |||
$leftType = self::TYPE_IDENTIFIER , |
|||
$rightType = self::TYPE_VALUE |
|||
) |
Create "Less Than" predicate.
Utilizes Operator predicate
int | float | bool | string | $left | |
int | float | bool | string | $right | |
string | $leftType | TYPE_IDENTIFIER or TYPE_VALUE by default TYPE_IDENTIFIER { |
string | $rightType | TYPE_IDENTIFIER or TYPE_VALUE by default TYPE_VALUE { |
lessThanOrEqualTo | ( | $left, | |
$right, | |||
$leftType = self::TYPE_IDENTIFIER , |
|||
$rightType = self::TYPE_VALUE |
|||
) |
Create "Less Than Or Equal To" predicate.
Utilizes Operator predicate
int | float | bool | string | $left | |
int | float | bool | string | $right | |
string | $leftType | TYPE_IDENTIFIER or TYPE_VALUE by default TYPE_IDENTIFIER { |
string | $rightType | TYPE_IDENTIFIER or TYPE_VALUE by default TYPE_VALUE { |
like | ( | $identifier, | |
$like | |||
) |
literal | ( | $literal | ) |
Create "Literal" predicate.
Literal predicate, for parameters, use expression()
string | $literal |
nest | ( | ) |
Begin nesting predicates.
notBetween | ( | $identifier, | |
$minValue, | |||
$maxValue | |||
) |
Create "NOT BETWEEN" predicate.
Utilizes NotBetween predicate
string | $identifier | |
int | float | string | $minValue | |
int | float | string | $maxValue |
notEqualTo | ( | $left, | |
$right, | |||
$leftType = self::TYPE_IDENTIFIER , |
|||
$rightType = self::TYPE_VALUE |
|||
) |
Create "Not Equal To" predicate.
Utilizes Operator predicate
int | float | bool | string | $left | |
int | float | bool | string | $right | |
string | $leftType | TYPE_IDENTIFIER or TYPE_VALUE by default TYPE_IDENTIFIER { |
string | $rightType | TYPE_IDENTIFIER or TYPE_VALUE by default TYPE_VALUE { |
notIn | ( | $identifier, | |
$valueSet = null |
|||
) |
notLike | ( | $identifier, | |
$notLike | |||
) |
predicate | ( | PredicateInterface | $predicate | ) |
Use given predicate directly.
Contrary to addPredicate() this method respects formerly set AND / OR combination operator, thus allowing generic predicates to be used fluently within where chains as any other concrete predicate.
PredicateInterface | $predicate |
setUnnest | ( | Predicate | $predicate | ) |
unnest | ( | ) |
|
protected |
|
protected |