Contents
Interface AsyncPositionPredicate
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
A predicate that tests a position in a world and may have to load data to answer.
Implementations return an already-completed future when they can answer from data in memory.
AsyncSpatialSearch relies on that to keep a search that needs no loads synchronous.
-
Method Summary
Modifier and TypeMethodDescriptionDetermines if the condition is met at the specified point in the given world.
-
Method Details
-
testAsync
@Nonnull CompletableFuture<Boolean> testAsync(@Nonnull World world, @Nonnull org.joml.Vector3d point) Determines if the condition is met at the specified point in the given world.- Parameters:
world- The world to test the condition in.point- The point to test the condition at.- Returns:
- a future completing with
trueif the condition is met.
-