1 package net.sf.flock.filter;
2
3 import java.util.Comparator;
4
5 import net.sf.flock.ItemI;
6
7 /***
8 * @version $Revision$
9 * @author $Author$
10 */
11 class ItemDateComparator implements Comparator {
12
13 private boolean reverse = true;
14
15 /***
16 * @see java.util.Comparator#compare(Object, Object)
17 */
18 public int compare(Object arg0, Object arg1) {
19 ItemI article0 = (ItemI) arg0;
20 ItemI article1 = (ItemI) arg1;
21
22 int d = article0.getCreationTime().compareTo(article1.getCreationTime());
23 return d!=0 ? (this.reverse ? -d : d) : article0.getTitle().compareTo(article1.getTitle());
24 }
25
26 }
This page was automatically generated by Maven