Documentation

Comparison : string
in package

Table of Contents

Cases

Between  = 'BETWEEN'
Contains  = 'CONTAINS'
EndsWith  = 'ENDS_WITH'
Equals  = '='
GreaterThan  = '>'
GreaterThanOrEqual  = '>='
In  = 'IN'
LesserThan  = '<'
LesserThanOrEqual  = '<='
NotBetween  = 'NBETWEEN'
NotContain  = 'NCONTAIN'
NotEquals  = '!='
NotIn  = 'NIN'
NotRegexp  = 'NREGEXP'
Regexp  = 'REGEXP'
StartsWith  = 'STARTS_WITH'

Methods

accept()  : void
Assert if the reference value can be used with the Enum operator.
compare()  : bool
Values comparison.
fromOperator()  : self
tryFromOperator()  : self|null
isSingleValue()  : bool

Cases

Methods

accept()

Assert if the reference value can be used with the Enum operator.

public accept(mixed $reference) : void
Parameters
$reference : mixed
Tags
throws
QueryException

compare()

Values comparison.

public compare(mixed $subject, mixed $reference) : bool

The method return true if the values satisfy the comparison operator, otherwise false is returned.

Parameters
$subject : mixed
$reference : mixed
Tags
throws
QueryException
Return values
bool

fromOperator()

public static fromOperator(string $operator) : self
Parameters
$operator : string
Tags
throws
QueryException
Return values
self

tryFromOperator()

public static tryFromOperator(string $operator) : self|null
Parameters
$operator : string
Return values
self|null

isSingleValue()

private static isSingleValue(mixed $value) : bool
Parameters
$value : mixed
Return values
bool

        
On this page

Search results