|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjava.util.AbstractCollection
java.util.AbstractList
java.util.ArrayList
query.QueryList
This class extends ArrayList and contains methods to sort and filter.
| Field Summary |
| Fields inherited from class java.util.AbstractList |
modCount |
| Constructor Summary | |
QueryList()
|
|
| Method Summary | |
QueryList |
filter(Operator operator)
filters QueryList which contains only those beans which satisfies the operator condition. |
boolean |
sort(java.lang.String fieldName)
Overridden method for sorting. |
boolean |
sort(java.lang.String[] fieldNames,
boolean ascending)
sorts the QueryList by the fieldNames in ascending or descending order. |
boolean |
sort(java.lang.String[] fieldNames,
boolean[] ascending)
sorts the QueryList by the fieldNames in ascending or descending order. |
boolean |
sort(java.lang.String fieldName,
boolean ascending)
sorts the QueryList by the fieldName in ascending or descending order. |
boolean |
sort(java.lang.String fieldName,
boolean ascending,
boolean ignoreCase)
sorts the QueryList by the fieldName in ascending or descending order. |
double |
sum(java.lang.String fieldName)
calculates the sum of the field in this QueryList. |
double |
sum(java.lang.String fieldName,
java.lang.Class arg,
java.lang.Object value)
calculates the sum of the field in this QueryList. |
double |
sum(java.lang.String fieldName,
Operator operator)
calculates the sum of the field in this QueryList. |
java.lang.String |
toString()
Overridden method of super class, java.util.ArrayList. |
| Methods inherited from class java.util.ArrayList |
add, add, addAll, addAll, clear, clone, contains, ensureCapacity, get, indexOf, isEmpty, lastIndexOf, remove, removeRange, set, size, toArray, toArray, trimToSize |
| Methods inherited from class java.util.AbstractList |
equals, hashCode, iterator, listIterator, listIterator, subList |
| Methods inherited from class java.util.AbstractCollection |
containsAll, remove, removeAll, retainAll |
| Methods inherited from class java.lang.Object |
finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface java.util.List |
containsAll, equals, hashCode, iterator, listIterator, listIterator, remove, removeAll, retainAll, subList |
| Constructor Detail |
public QueryList()
| Method Detail |
public boolean sort(java.lang.String fieldName)
fieldName - field which is used to sort the bean.
public boolean sort(java.lang.String fieldName,
boolean ascending)
fieldName - field which is used to sort the bean.ascending - if true sorting is done in ascending order,
else sorting is done in descending order.
public boolean sort(java.lang.String fieldName,
boolean ascending,
boolean ignoreCase)
ignoreCase - use only when comparing strings. as default implementation uses case sensitive comparison.fieldName - field which is used to sort the bean.ascending - if true sorting is done in ascending order,
else sorting is done in descending order.
public boolean sort(java.lang.String[] fieldNames,
boolean ascending)
fieldNames - fields which is used to sort the bean.ascending - if true sorting is done in ascending order,
else sorting is done in descending order.
public boolean sort(java.lang.String[] fieldNames,
boolean[] ascending)
fieldNames - fields which is used to sort the bean.ascending - if true sorting is done in ascending order,
else sorting is done in descending order.
public QueryList filter(Operator operator)
operator - Operator.
public double sum(java.lang.String fieldName)
fieldName - field of bean whose sum has to be calculated.
public double sum(java.lang.String fieldName,
java.lang.Class arg,
java.lang.Object value)
fieldName - field of bean whose sum has to be calculated.arg - argument for the getter method of field if it takes any argumnt,
else can be null.value - value for the argument, else can be null.
public double sum(java.lang.String fieldName,
Operator operator)
fieldName - field of bean whose sum has to be calculated.operator - to get filrtered vector on which sum will be called.
public java.lang.String toString()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||