public static class FAQUtils.VoteComparator extends Object implements Comparator<org.exoplatform.faq.service.Answer>
| Modifier and Type | Field and Description |
|---|---|
protected boolean |
isASC |
| Constructor and Description |
|---|
VoteComparator(boolean isASC) |
| Modifier and Type | Method and Description |
|---|---|
int |
compare(org.exoplatform.faq.service.Answer answer1,
org.exoplatform.faq.service.Answer answer2) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitcomparing, comparing, comparingDouble, comparingInt, comparingLong, equals, naturalOrder, nullsFirst, nullsLast, reversed, reverseOrder, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLongpublic VoteComparator(boolean isASC)
isASC - the type of comparator.
+ isASC == true: comparator by ascending
+ isASC == false: comparator by descendingpublic int compare(org.exoplatform.faq.service.Answer answer1,
org.exoplatform.faq.service.Answer answer2)
compare in interface Comparator<org.exoplatform.faq.service.Answer>Copyright © 2003–2017 eXo Platform SAS. All rights reserved.