We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8bd838e commit 2b56227Copy full SHA for 2b56227
src/main/kotlin/app/utils/Misc.kt
@@ -10,7 +10,7 @@ fun <T> Sequence<T>.batch(n: Int): Sequence<List<T>> {
10
}
11
12
class BatchingSequence<T>(val source: Sequence<T>,
13
- val batchSize: Int) : Sequence<List<T>> {
+ val batchSize: Int) : Sequence<List<T>> {
14
override fun iterator(): Iterator<List<T>> = object :
15
AbstractIterator<List<T>>() {
16
val iterate = if (batchSize > 0) source.iterator() else
@@ -21,4 +21,4 @@ class BatchingSequence<T>(val source: Sequence<T>,
21
else done()
22
23
24
-}
+}
0 commit comments