java - How to pause a Thread's Message Queue in Android? -


i queuing bunch of runnables thread via handler.post(). ability send note thread should pause.

by pause mean, finish runnable or message working on, don't go next message or runnable in message queue until tell continue.

in case else finds way question, ended going threadpoolexecutor, using example code in it's documentation creating pausablethreadpoolexecutor: http://download.oracle.com/javase/1.5.0/docs/api/java/util/concurrent/threadpoolexecutor.html

it doesn't use message queue or looper accomplishes trying do, create queue of runnables able paused and/or canceled. has added bonus of being able spread queue on specified number of threads.


Comments

Popular posts from this blog

ASP.NET/SQL find the element ID and update database -

jquery - appear modal windows bottom -

c++ - Compiling static TagLib 1.6.3 libraries for Windows -