File tree Expand file tree Collapse file tree 2 files changed +4
-5
lines changed
kotlinx-coroutines-rx2/src/test/kotlin/guide Expand file tree Collapse file tree 2 files changed +4
-5
lines changed Original file line number Diff line number Diff line change @@ -350,7 +350,7 @@ fun main(args: Array<String>) = runBlocking<Unit> {
350
350
.doOnComplete { println (" Complete" ) }
351
351
.subscribe { x ->
352
352
println (" Received $x " )
353
- Thread .sleep(200 ) // 200 ms to process each item
353
+ Thread .sleep(300 ) // 300 ms to process each item
354
354
}
355
355
delay(2000 ) // suspend main thread for couple of seconds
356
356
}
Original file line number Diff line number Diff line change 17
17
// This file was automatically generated from coroutines-guide-reactive.md by Knit tool. Do not edit.
18
18
package guide.reactive.basic.example05
19
19
20
- import io.reactivex.schedulers.Schedulers
21
- import kotlinx.coroutines.experimental.delay
22
- import kotlinx.coroutines.experimental.runBlocking
20
+ import kotlinx.coroutines.experimental.*
23
21
import kotlinx.coroutines.experimental.rx2.rxFlowable
22
+ import io.reactivex.schedulers.Schedulers
24
23
25
24
fun main (args : Array <String >) = runBlocking<Unit > {
26
25
// coroutine -- fast producer of elements in the context of the main thread
@@ -36,7 +35,7 @@ fun main(args: Array<String>) = runBlocking<Unit> {
36
35
.doOnComplete { println (" Complete" ) }
37
36
.subscribe { x ->
38
37
println (" Received $x " )
39
- Thread .sleep(200 ) // 200 ms to process each item
38
+ Thread .sleep(300 ) // 300 ms to process each item
40
39
}
41
40
delay(2000 ) // suspend main thread for couple of seconds
42
41
}
You can’t perform that action at this time.
0 commit comments