|
Apache CXF API | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
T
- Type of the object which will be checked by SearchCondition instancepublic interface SearchCondition<T>
Can be used to build plain or complex/composite search conditions.
Google Collections Predicate might've been used instead, but it is a too generic and its apply method is not quite needed here
Method Summary | |
---|---|
List<T> |
findAll(Collection<T> pojos)
Returns a list of pojos matching the condition |
T |
getCondition()
Some SearchConditions may use instance of T to capture the actual search criteria thus making it simpler to implement isMet(T). |
ConditionType |
getConditionType()
Type of condition this SearchCondition represents |
List<SearchCondition<T>> |
getSearchConditions()
List of conditions this SearchCondition may represent |
PrimitiveStatement |
getStatement()
Primitive statement such a > b, i < 5, etc this condition may represent |
boolean |
isMet(T pojo)
Checks if the given pojo instance meets this search condition |
String |
toSQL(String table,
String... columns)
Utility method for converting this condition into an SQL expression |
Method Detail |
---|
boolean isMet(T pojo)
pojo
- the object which will be checked
List<T> findAll(Collection<T> pojos)
pojos
- list of pojos
T getCondition()
PrimitiveStatement getStatement()
List<SearchCondition<T>> getSearchConditions()
ConditionType getConditionType()
String toSQL(String table, String... columns)
table
- table namecolumns
- column names, a wildcard as in 'SELECT * from table' will be used
if names are not provided
|
Apache CXF API | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |