Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
 /*     */ package org.apache.commons.collections.comparators;
 /*     */ 
 /*     */ import java.io.Serializable;
 /*     */ import java.util.Comparator;
 /*     */ 
 /*     */ public class ReverseComparator
 /*     */   implements ComparatorSerializable
 /*     */ {
 /*     */   private static final long serialVersionUID = 2858887242028539265L;
/*     */   private Comparator comparator;
/*     */ 
/*     */   public ReverseComparator()
/*     */   {
/*  51 */     this(null);
/*     */   }
/*     */ 
/*     */   public ReverseComparator(Comparator comparator)
/*     */   {
/*  64 */     if (comparator != null)
/*  65 */       this. = comparator;
/*     */     else
/*  67 */       this. = ComparableComparator.getInstance();
/*     */   }
/*     */ 
/*     */   public int compare(Object obj1Object obj2)
/*     */   {
/*  80 */     return this..compare(obj2obj1);
/*     */   }
/*     */ 
/*     */   public int hashCode()
/*     */   {
/*  92 */     return "ReverseComparator".hashCode() ^ this..hashCode();
/*     */   }
/*     */ 
/*     */   public boolean equals(Object object)
/*     */   {
/* 112 */     if (this == object)
/* 113 */       return true;
/* 114 */     if (null == object)
/* 115 */       return false;
/* 116 */     if (object.getClass().equals(getClass())) {
/* 117 */       ReverseComparator thatrc = (ReverseComparator)object;
/* 118 */       return this..equals(thatrc.comparator);
/*     */     }
/* 120 */     return false;
/*     */   }
/*     */ }
/* Location:           /home/mnovotny/projects/EMBEDDED_JBOSS_BETA3_COMMUNITY/embedded/output/lib/embedded-jboss/lib/thirdparty-all.jar
 * Qualified Name:     org.apache.commons.collections.comparators.ReverseComparator
 * JD-Core Version:    0.6.0
 */
New to GrepCode? Check out our FAQ X