Class EntryListBooleanComparator

java.lang.Object
com.isode.dsapi.util.EntryListBooleanComparator
All Implemented Interfaces:
Comparator<Entry>
Direct Known Subclasses:
EntryListBooleanAttributeComparator

public abstract class EntryListBooleanComparator extends Object implements Comparator<Entry>
Boolean comparator for use with EntryList class
Author:
mst
  • Field Details

    • ascending

      protected boolean ascending
  • Constructor Details

    • EntryListBooleanComparator

      public EntryListBooleanComparator(boolean ascending)
      Constructor
      Parameters:
      ascending - ascending order
  • Method Details

    • getValueBoolean

      protected abstract boolean getValueBoolean(Entry entry)
      Return boolean value generated from source entry
      Parameters:
      entry - source entry
    • compare

      public int compare(Entry e1, Entry e2)
      compare method used by sorting algorithm
      Specified by:
      compare in interface Comparator<Entry>
      Parameters:
      e1 - first entry to compare
      e2 - second entry to compare