Class SortedScheduledEntries<K,V extends Comparable<? super V>>

java.lang.Object
org.wildfly.clustering.ee.cache.scheduler.SortedScheduledEntries<K,V>
All Implemented Interfaces:
Iterable<Map.Entry<K,V>>, ScheduledEntries<K,V>

public class SortedScheduledEntries<K,V extends Comparable<? super V>> extends Object implements ScheduledEntries<K,V>
ScheduledEntries implemented using a ConcurrentSkipListSet, where entries are sorted based on the entry value. Both add(Object, Comparable) and remove(Object) run in O(log N) time.
Author:
Paul Ferraro
  • Constructor Details

    • SortedScheduledEntries

      public SortedScheduledEntries()
      Creates a new entries object whose iteration order is based on the entry value.
    • SortedScheduledEntries

      public SortedScheduledEntries(Comparator<Map.Entry<K,V>> comparator)
      Creates a new entries object whose iteration order is based on the specified comparator.
      Parameters:
      comparator - the comparator used to determine the iteration order
  • Method Details