Brief:
-
Used HandleThread to manage different tasks
-
Used two class CustomHandler and UiHandler within serviceWorker to manage callbacks on different Threads.
-
onExecute works async on background thread with repective instance of serviceWorker thread process.
-
Recieve Callback after executing tasks on onExecute to onTaskComplete in UiThreads with help of UiThreadCallback.