Package net.minecraft.util.thread
Class ParallelMapTransform.SplitterBase<K,U,V>
java.lang.Object
net.minecraft.util.thread.ParallelMapTransform.SplitterBase<K,U,V>
- Direct Known Subclasses:
ParallelMapTransform.BatchedTaskSplitter
,ParallelMapTransform.SingleTaskSplitter
- Enclosing class:
ParallelMapTransform
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate int
private final ParallelMapTransform.Container
<K, U, V> private int
private int
private final CompletableFuture<?>[]
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected abstract int
batchSize
(int p_405377_) private int
protected abstract CompletableFuture
<?> scheduleBatch
(ParallelMapTransform.Container<K, U, V> p_405692_, int p_404873_, int p_405552_, Executor p_405568_) protected abstract CompletableFuture
<Map<K, V>> scheduleFinalOperation
(CompletableFuture<?> p_405448_, ParallelMapTransform.Container<K, U, V> p_405155_) scheduleTasks
(Map<K, U> p_405332_, Executor p_405350_)
-
Field Details
-
lastScheduledIndex
private int lastScheduledIndex -
currentIndex
private int currentIndex -
tasks
-
batchIndex
private int batchIndex -
container
-
-
Constructor Details
-
SplitterBase
SplitterBase(BiFunction<K, U, V> p_405196_, int p_405517_, int p_405788_)
-
-
Method Details
-
pendingBatchSize
private int pendingBatchSize() -
scheduleTasks
-
batchSize
protected abstract int batchSize(int p_405377_) -
scheduleBatch
protected abstract CompletableFuture<?> scheduleBatch(ParallelMapTransform.Container<K, U, V> p_405692_, int p_404873_, int p_405552_, Executor p_405568_) -
scheduleFinalOperation
protected abstract CompletableFuture<Map<K,V>> scheduleFinalOperation(CompletableFuture<?> p_405448_, ParallelMapTransform.Container<K, U, V> p_405155_)
-