Class AbstractComparator<T>

java.lang.Object
org.codehaus.groovy.runtime.AbstractComparator<T>
All Implemented Interfaces:
Comparator<T>

public abstract class AbstractComparator<T> extends Object implements Comparator<T>
Base class for Groovy comparators. Provides a common implementation where equality is based on object identity.
  • Constructor Details

    • AbstractComparator

      public AbstractComparator()
  • Method Details

    • equals

      public boolean equals(Object obj)
      Tests for equality based on object identity.
      Specified by:
      equals in interface Comparator<T>
      Overrides:
      equals in class Object
      Parameters:
      obj - the object to compare with
      Returns:
      true if this object is the same as the specified object