Class ResultsVectorList
Object
ResultsVectorList
- All Implemented Interfaces:
Iterable<ResultsVector>
A list of elements of type
ResultsVector
.- Author:
- Owen Feehan
-
Constructor Summary
ConstructorsConstructorDescriptionResultsVectorList
(ResultsVector results) Creates with the list containing a single item. -
Method Summary
Modifier and TypeMethodDescriptionvoid
add
(ResultsVector results) Add aResultsVector
to the list in the final position.get
(int index) Gets aResultsVector
at a particular position i nthe list.boolean
isEmpty()
Returnstrue
if the list contains no elements.iterator()
int
size()
The number ofResultsVector
s in the list.stream()
A stream ofResultsVector
s.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
Constructor Details
-
ResultsVectorList
Creates with the list containing a single item.- Parameters:
results
- the single item for the list.
-
ResultsVectorList
public ResultsVectorList()
-
-
Method Details
-
add
Add aResultsVector
to the list in the final position.- Parameters:
results
- the results to add.
-
size
public int size()The number ofResultsVector
s in the list.- Returns:
- the total number.
-
get
Gets aResultsVector
at a particular position i nthe list.- Parameters:
index
- the position (zero-indexed).- Returns:
- the vector at the position.
-
iterator
- Specified by:
iterator
in interfaceIterable<ResultsVector>
-
stream
A stream ofResultsVector
s.- Returns:
- the stream.
-
isEmpty
public boolean isEmpty()Returnstrue
if the list contains no elements.- Returns:
true
if the list contains no elements
-