lwc:programming:mobile:android:threads

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
lwc:programming:mobile:android:threads [2022/02/23 06:44] John Harrisonlwc:programming:mobile:android:threads [2022/05/11 19:03] (current) John Harrison
Line 3: Line 3:
 ==== Run a routine every second ==== ==== Run a routine every second ====
 === With Handler === === With Handler ===
-//I assume since this is with ''Handler'' and ''Runnable'' that this is in a separate thread? How to confirm?// 
 <code> <code>
 final Handler handler = new Handler(); final Handler handler = new Handler();
Line 16: Line 15:
 </code> </code>
 === With Timer === === With Timer ===
-//Does this run in separate thread?// 
 <code> <code>
 new Timer().scheduleAtFixedRate(new TimerTask() { new Timer().scheduleAtFixedRate(new TimerTask() {
  • lwc/programming/mobile/android/threads.1645620294.txt.gz
  • Last modified: 2022/02/23 06:44
  • by John Harrison