void (@NotNull ProgressIndicator indicator) { for (int i = 0; i < 100; i++) { int taskId = i; service().runTaskSynchronously(new DumbModeTaskWithEquivalentObject("child") { @Override public void performInDumbMode(@NotNull ProgressIndicator indicator) { childLog.add(taskId); } @Override public void dispose() { disposeLog.add(taskId); } }); } }