类 AsyncService

java.lang.Object
pkg.exoad.poprock.core.AsyncService

@ServiceClass(requiresArming=false) public final class AsyncService extends Object
AsyncService - A utility class providing some basic asynchronous functionalities.
作者:
Jack Meng
  • 字段详细资料

    • WORKER1

      public static final Timer WORKER1
      WORKER1 delegates all of the routine tasks that either run as daemons or periodically.
      另请参阅:
    • WORKER2

      public static final ExecutorService WORKER2
      WORKER2 delegates all of the other options for a ForkJoinPool for a workstealing thread pool.
  • 构造器详细资料

    • AsyncService

      private AsyncService()
  • 方法详细资料

    • runAsync

      public static void runAsync(Runnable runnable)
      Invokes a task on a new Thread object and runs it concurrently immediately (or when the JVM is ready)
      参数:
      runnable - The task
    • runPeriodicTask

      public static void runPeriodicTask(long period, long initialDelay, Runnable task)