INNER CODE UNIT · Java

BackgroundHandler

yuliskov/SmartTubeLegacy · browser/src/main/java/com/liskovsoft/browser/BackgroundHandler.java:25

public class BackgroundHandler {

    static HandlerThread sLooperThread;
    static ExecutorService mThreadPool;

    static {
        sLooperThread = new HandlerThread("BackgroundHandler", HandlerThread.MIN_PRIORITY);
        sLooperThread.start();
        mThreadPool = Executors.newCachedThreadPool();
    }

    public static void execute(Runnable runnable) {
        mThreadPool.execute(runnable);
    }

    public static Future<?> submit(Runnable runnable) {
        return mThreadPool.submit(runnable);
    }

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…