public class CriterionDecoder extends Object
| Modifier and Type | Field and Description |
|---|---|
protected MetaTable |
baseTable |
protected Criterion |
criterion |
protected SqlDialect |
dialect |
protected OrmHandler |
handler |
protected List<ValueCriterion> |
nullValues |
protected List<Key> |
orderBy |
protected boolean |
printAllJoinedTables
EFFECTIVA REQUEST: to enforce printing all Ujorm joined tables
|
protected StringBuilder |
sql |
protected Set<MetaTable> |
tables |
protected List<ValueCriterion> |
values |
| Constructor and Description |
|---|
CriterionDecoder(Criterion criterion,
MetaTable baseTable)
Constructor
|
CriterionDecoder(Criterion criterion,
MetaTable baseTable,
List<Key> orderByItems)
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
Key |
getBaseProperty()
Returns the first direct property.
|
MetaTable |
getBaseTable()
Get Base Table
|
MetaColumn |
getColumn(int i)
Returns direct column or throw an exception
|
int |
getColumnCount()
Returns a column count
|
Criterion |
getCriterion()
Returns the criterion from costructor.
|
OrmHandler |
getHandler()
Returns handler
|
Operator |
getOperator(int i)
Returns operator.
|
protected Key[] |
getPropertyRelations()
Returns the unique direct property relations.
|
int |
getTableCount()
Returns all participated tables include the parameter table.
|
TableWrapper[] |
getTables()
Returns all participated tables include the parameter table.
|
TableWrapper[] |
getTablesSorted()
Returns all participated tables include the parameter table.
|
Object |
getValue(int i)
Returns value
|
Object |
getValueExtended(int i)
Returns an extended value to the SQL statement
|
String |
getWhere()
Returns a SQL WHERE 'expression' of an empty string if no conditon is found.
|
boolean |
isEmpty()
Is the SQL statement empty?
|
String |
toString()
Returns the criterion
|
protected void |
unpack(Criterion c)
Unpack criterion.
|
protected void |
writeRelations()
Writer a relation conditions:
|
protected final OrmHandler handler
protected final SqlDialect dialect
protected final Criterion criterion
protected final StringBuilder sql
protected final List<ValueCriterion> values
protected final List<ValueCriterion> nullValues
protected final MetaTable baseTable
protected final boolean printAllJoinedTables
public CriterionDecoder(Criterion criterion, MetaTable baseTable)
criterion - Criterion non-nullbaseTable - Base ORM table modelprotected void unpack(Criterion c)
public int getColumnCount()
public MetaColumn getColumn(int i) throws IllegalArgumentException
IllegalArgumentExceptionpublic Operator getOperator(int i)
public Object getValue(int i)
public Object getValueExtended(int i)
public Criterion getCriterion()
public String getWhere()
public boolean isEmpty()
public Key getBaseProperty()
protected void writeRelations()
protected Key[] getPropertyRelations()
public MetaTable getBaseTable()
public int getTableCount()
public TableWrapper[] getTables()
public TableWrapper[] getTablesSorted()
public OrmHandler getHandler()
Copyright 2013, Pavel Ponec