Class LevelResultCollection
Object
LevelResultCollection
- All Implemented Interfaces:
Iterable<LevelResult>
A collection of
LevelResult objects that can be iterated over and searched.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanadd(LevelResult arg0) Adds aLevelResultto the collection.findClosestResult(Point3i point) Finds theLevelResultclosest to a given point.iterator()Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.lang.Iterable
forEach, spliterator
-
Constructor Details
-
LevelResultCollection
public LevelResultCollection()
-
-
Method Details
-
add
Adds aLevelResultto the collection.- Parameters:
arg0- theLevelResultto add- Returns:
- true if the collection changed as a result of the call
-
findClosestResult
Finds theLevelResultclosest to a given point.- Parameters:
point- thePoint3ito find the closest result to- Returns:
- the
LevelResultclosest to the given point, or null if the collection is empty
-
iterator
- Specified by:
iteratorin interfaceIterable<LevelResult>
-