File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed
Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -21,28 +21,28 @@ dependencies {
2121ThreadSwitcher .newChain() // Create an empty chain.
2222 // Concat a UI chain to the empty chain.
2323 .onUI {
24- // Some tasks to do on UI Thread
24+ // Some tasks to do on a UI Thread
2525 " result" // Pass any value to the next chain.
2626 }
2727 // Concat a Worker chain to the previous chain.
2828 .onWorker { result: String -> // Receive the value from the previous chain.
2929 // Some tasks to do on Worker Thread
3030 }
3131 .onUI {
32- // Some tasks to do on UI Thread
32+ // Some tasks to do on a UI Thread
3333 }
3434 .onWorker {
35- // Some tasks to do on Worker Thread
35+ // Some tasks to do on a Worker Thread
3636 " data"
3737 }
3838
39- // Start to perform all chains from top to bottom.
39+ // Start to perform all chains from the top to bottom.
4040 .start(
4141 // onSuccess callback would be invoked when all chains are finished without any exception.
4242 onSuccess = { result: String -> // The type of parameter is settled by the return value of last chain.
4343 },
4444
45- // onError callback would be invoked when an exception occurred during the performance of chains.
45+ // onError callback would be invoked when an exception occurred during performancing chains.
4646 onError = { e: Throwable -> // The exception
4747 })
4848```
You can’t perform that action at this time.
0 commit comments