class ModelCriterion extends Criterion
This is an "inner" class that describes an object in the criteria.
Constants
UND |
|
ODER |
|
Methods
__construct(Criteria $outer, $column, $value = null, $comparison = ModelCriteria::MODEL_CLAUSE, $clause)
Create a new instance. |
||
init(Criteria $criteria)
Init some properties with the help of outer class |
from Criterion | |
string |
getColumn()
Get the column name. |
from Criterion |
void |
setTable(name $name)
Set the table name. |
from Criterion |
string |
getTable()
Get the table name. |
from Criterion |
string |
getComparison()
Get the comparison. |
from Criterion |
mixed |
getValue()
Get the value. |
from Criterion |
DBAdapter |
getDB()
Get the value of db. |
from Criterion |
void |
setDB(DBAdapter $v)
Set the value of db. |
from Criterion |
Criterion |
setIgnoreCase(boolean $b)
Sets ignore case. |
from Criterion |
boolean |
isIgnoreCase()
Is ignore case on or off? |
from Criterion |
array |
getConjunctions()
Get the list of conjunctions in this Criterion |
from Criterion |
addAnd(Criterion $criterion)
Append an AND Criterion onto this Criterion's list. |
from Criterion | |
Criterion |
addOr(Criterion $criterion)
Append an OR Criterion onto this Criterion's list. |
from Criterion |
void |
appendPsTo(string $sb, array $params)
Appends a Prepared Statement representation of the Criterion onto the buffer. |
from Criterion |
boolean |
equals($obj)
This method checks another Criteria to see if they contain the same attributes and hashtable entries. |
|
hashCode()
Returns a hash code value for the object. |
||
array |
getAllTables()
Get all tables from nested criterion objects |
from Criterion |
array |
getAttachedCriterion()
get an array of all criterion attached to this recursing through all sub criterion |
from Criterion |
__clone()
Ensures deep cloning of attached objects |
from Criterion | |
getClause() | ||
appendModelClauseToPs(string $sb, array $params)
Appends a Prepared Statement representation of the ModelCriterion onto the buffer For regular model clauses, e.g. |
||
appendModelClauseLikeToPs(string $sb, array $params)
Appends a Prepared Statement representation of the ModelCriterion onto the buffer For LIKE model clauses, e.g. |
||
appendModelClauseSeveralToPs(string $sb, array $params)
Appends a Prepared Statement representation of the ModelCriterion onto the buffer For ternary model clauses, e.G 'book.ID BETWEEN ? AND ?' |
||
appendModelClauseArrayToPs(string $sb, array $params)
Appends a Prepared Statement representation of the ModelCriterion onto the buffer For IN or NOT IN model clauses, e.g. |
Details
at line 31
public
__construct(Criteria $outer, $column, $value = null, $comparison = ModelCriteria::MODEL_CLAUSE, $clause)
Create a new instance.
in Criterion at line 89
public
init(Criteria $criteria)
Init some properties with the help of outer class
in Criterion at line 112
public string
getColumn()
Get the column name.
in Criterion at line 123
public void
setTable(name $name)
Set the table name.
in Criterion at line 133
public string
getTable()
Get the table name.
in Criterion at line 143
public string
getComparison()
Get the comparison.
in Criterion at line 153
public mixed
getValue()
Get the value.
in Criterion at line 164
public DBAdapter
getDB()
Get the value of db.
The DBAdapter which might be used to get db specific
variations of sql.
in Criterion at line 175
public void
setDB(DBAdapter $v)
Set the value of db.
The DBAdapter might be used to get db specific variations of sql.
in Criterion at line 189
public Criterion
setIgnoreCase(boolean $b)
Sets ignore case.
in Criterion at line 200
public boolean
isIgnoreCase()
Is ignore case on or off?
in Criterion at line 218
public array
getConjunctions()
Get the list of conjunctions in this Criterion
in Criterion at line 226
public
addAnd(Criterion $criterion)
Append an AND Criterion onto this Criterion's list.
in Criterion at line 237
public Criterion
addOr(Criterion $criterion)
Append an OR Criterion onto this Criterion's list.
in Criterion at line 254
public void
appendPsTo(string $sb, array $params)
Appends a Prepared Statement representation of the Criterion onto the buffer.
at line 199
public boolean
equals($obj)
This method checks another Criteria to see if they contain the same attributes and hashtable entries.
at line 240
public
hashCode()
Returns a hash code value for the object.
in Criterion at line 500
public array
getAllTables()
Get all tables from nested criterion objects
in Criterion at line 525
public array
getAttachedCriterion()
get an array of all criterion attached to this recursing through all sub criterion
in Criterion at line 537
public
__clone()
Ensures deep cloning of attached objects
at line 53
public
getClause()
at line 118
public
appendModelClauseToPs(string $sb, array $params)
Appends a Prepared Statement representation of the ModelCriterion onto the buffer For regular model clauses, e.g.
'book.TITLE = ?'
at line 136
public
appendModelClauseLikeToPs(string $sb, array $params)
Appends a Prepared Statement representation of the ModelCriterion onto the buffer For LIKE model clauses, e.g.
'book.TITLE LIKE ?'
Handles case insensitivity for VARCHAR columns
at line 153
public
appendModelClauseSeveralToPs(string $sb, array $params)
Appends a Prepared Statement representation of the ModelCriterion onto the buffer For ternary model clauses, e.G 'book.ID BETWEEN ? AND ?'
at line 176
public
appendModelClauseArrayToPs(string $sb, array $params)
Appends a Prepared Statement representation of the ModelCriterion onto the buffer For IN or NOT IN model clauses, e.g.
'book.TITLE NOT IN ?'