Package net.minestom.server.thread
Interface ThreadProvider<T>
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic enumDefines how often chunks thread should be refreshed. -
Method Summary
Modifier and TypeMethodDescriptionstatic <T> @NotNull ThreadProvider<T> counter()intfindThread(T partition) Performs a server tick for all chunks based on their linked thread.default @NotNull ThreadProvider.RefreshTypeDefines how often chunks thread should be updated.
-
Method Details
-
counter
-
findThread
Performs a server tick for all chunks based on their linked thread.- Parameters:
partition- the partition
-
refreshType
Defines how often chunks thread should be updated.- Returns:
- the refresh type
-