/** * Execute a task. * * @param runnable the task to execute */ public static void execute(Runnable runnable) { directExecute(runnable, 0); }
/** * Execute a task after the given delay. * * @param runnable the task to execute * @param delay the time from now to delay execution, in milliseconds * @throws IllegalArgumentException if <code>delay</code> is strictly positive and the current * executor does not support scheduling (if {@link #setExecutor(Executor)} has been called * with such an executor) */ public static void execute(Runnable runnable, int delay) { directExecute(runnable, delay); }