Interface ScheduledEntries<K,V>
- Type Parameters:
K- the scheduled entry key typeV- the scheduled entry value type
-
Method Summary
Modifier and TypeMethodDescriptionvoidAdds an entry using the specified key and value.booleanIndicates whether specified key exists among the scheduled entries.booleanisSorted()Indicates whether the entries are sorted, or if iteration order recapitulates insertion order.iterator()peek()Returns, but does not remove, the first entry.static <K,V> ScheduledEntries <K, V> queued()Creates a queue-based scheduled entries collection.voidRemoves the entry with the specified key.static <K, V extends Comparable<? super V>>
ScheduledEntries<K, V> sorted()Creates a sorted scheduled entries collection.static <K, V extends Comparable<? super V>>
ScheduledEntries<K, V> sorted(Comparator<Map.Entry<K, V>> comparator) Creates a sorted scheduled entries collection using the specified comparatorstream()Returns a stream of scheduled entries.Methods inherited from interface Iterable
forEach, spliterator
-
Method Details
-
isSorted
boolean isSorted()Indicates whether the entries are sorted, or if iteration order recapitulates insertion order.- Returns:
- true, if these entries are sorted, false otherwise.
-
add
-
remove
-
contains
Indicates whether specified key exists among the scheduled entries.- Parameters:
key- an entry key- Returns:
- true, if the key is a scheduled entry, false otherwise
-
peek
-
stream
-
iterator
-
queued
Creates a queue-based scheduled entries collection.- Type Parameters:
K- the entry key typeV- the entry value type- Returns:
- a queue-based scheduled entries collection.
-
sorted
Creates a sorted scheduled entries collection.- Type Parameters:
K- the entry key typeV- the entry value type- Returns:
- a sorted scheduled entries collection.
-
sorted
static <K, V extends Comparable<? super V>> ScheduledEntries<K,V> sorted(Comparator<Map.Entry<K, V>> comparator) Creates a sorted scheduled entries collection using the specified comparator- Type Parameters:
K- the entry key typeV- the entry value type- Parameters:
comparator- an entry comparator- Returns:
- a sorted scheduled entries collection.
-