Class SelectionImpl<T>
java.lang.Object
com.terracottatech.store.function.SelectionImpl<T>
- All Implemented Interfaces:
Selection<T>
,Iterable<T>
,Collection<T>
- Direct Known Subclasses:
TypedValueSelectionImpl
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.terracottatech.store.Selection
Selection.ComparableSelection<T extends Comparable<T>>, Selection.DoubleSelection, Selection.IntSelection, Selection.LongSelection, Selection.NumberSelection<T extends Number & Comparable<T>>
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
addAll
(Collection<? extends T> c) boolean
boolean
containsAll
(Collection<?> c) get
(int index) Fetch a value at a specific index in theSelection
.boolean
isEmpty()
iterator()
int
size()
Object[]
toArray()
<T1> T1[]
toArray
(T1[] a) toString()
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.util.Collection
equals, hashCode, parallelStream, spliterator, stream, toArray
Methods inherited from interface com.terracottatech.store.Selection
add, clear, first, firstOrElse, firstOrFail, getOrElse, getOrFail, last, lastOrElse, lastOrFail, remove, removeAll, removeIf, retainAll, sole, soleOrElse
-
Constructor Details
-
SelectionImpl
public SelectionImpl() -
SelectionImpl
-
-
Method Details
-
get
Description copied from interface:Selection
Fetch a value at a specific index in theSelection
. If the resolved index is outside the bounds of 0...size(), Optional.empty() will be returned. It supports negative indexes to allow for easy retrieval of tail values. -
size
public int size()- Specified by:
size
in interfaceCollection<T>
-
isEmpty
public boolean isEmpty()- Specified by:
isEmpty
in interfaceCollection<T>
-
contains
- Specified by:
contains
in interfaceCollection<T>
-
iterator
-
toArray
- Specified by:
toArray
in interfaceCollection<T>
-
toArray
public <T1> T1[] toArray(T1[] a) - Specified by:
toArray
in interfaceCollection<T>
-
containsAll
- Specified by:
containsAll
in interfaceCollection<T>
-
addAll
- Specified by:
addAll
in interfaceCollection<T>
-
toString
-