|
© 2002 BEA Systems, Inc. | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object | +--com.bea.p13n.content.document.ref.DocumentComparator
A comparator which can sort DocumentMetadataDefs according to a list of SortCriteria.
This will not be a fast comparator due to the nature of the objects it supports. It is recommended to try to get the database to do as much sorting as possible.
| Field Summary | |
protected SortCriteria[] |
criteria
The SortCriteria this uses. |
| Constructor Summary | |
DocumentComparator(SortCriteria[] criteria)
Constructor. |
|
DocumentComparator(java.lang.String sortBy)
Constructor. |
|
| Method Summary | |
int |
compare(java.lang.Object obj1,
java.lang.Object obj2)
Compare two DocumentMetadataDef objects according to the sort criteria. |
java.lang.String |
toString()
Get a string representation. |
| Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
wait,
wait,
wait |
| Field Detail |
protected SortCriteria[] criteria
| Constructor Detail |
public DocumentComparator(SortCriteria[] criteria)
public DocumentComparator(java.lang.String sortBy)
throws java.lang.IllegalArgumentException
sortBy - the sort by string to useSortCriteria.getSortCriteria(java.lang.String)| Method Detail |
public int compare(java.lang.Object obj1,
java.lang.Object obj2)
throws java.lang.ClassCastException
obj1 - the first object.obj2 - the second object.public java.lang.String toString()
|
© 2002 BEA Systems, Inc. | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||