public class AsyncInvokers extends Object
| 限定符和类型 | 方法和说明 |
|---|---|
static ExecutorService |
asyncExecutor() |
static void |
asyncExecutor(ExecutorService executor) |
static ScheduledExecutorService |
asyncScheduler() |
static void |
asyncScheduler(ScheduledExecutorService scheduler) |
static void |
doAsync(Consumer<ExecutorService> consumer) |
static Future<?> |
doAsync(Runnable task) |
static Future<?> |
doAsync(Runnable task,
long delay) |
static Future<?> |
doAsync(Runnable task,
long delay,
TimeUnit unit) |
static <T> Future<T> |
doAsync(Supplier<T> task) |
static <T> Future<T> |
doAsync(Supplier<T> task,
long delay) |
static <T> Future<T> |
doAsync(Supplier<T> task,
long delay,
TimeUnit unit) |
static Future<?> |
doAsyncRetry(Runnable runnable,
int retryCount,
Class<? extends Throwable>... retryException) |
static Future<?> |
doAsyncRetry(Runnable runnable,
int retryCount,
long interval,
boolean exponential,
Class<? extends Throwable>... retryException) |
static Future<?> |
doAsyncRetry(Runnable runnable,
int retryCount,
long interval,
Class<? extends Throwable>... retryException) |
static <T> Future<T> |
doAsyncRetry(Supplier<T> supplier,
int retryCount,
Class<? extends Throwable>... retryException) |
static <T> Future<T> |
doAsyncRetry(Supplier<T> supplier,
int retryCount,
long interval,
boolean exponential,
Class<? extends Throwable>... retryException) |
static <T> Future<T> |
doAsyncRetry(Supplier<T> supplier,
int retryCount,
long interval,
Class<? extends Throwable>... retryException) |
public static void asyncExecutor(ExecutorService executor)
public static void asyncScheduler(ScheduledExecutorService scheduler)
public static ExecutorService asyncExecutor()
public static ScheduledExecutorService asyncScheduler()
public static void doAsync(Consumer<ExecutorService> consumer)
@SafeVarargs public static <T> Future<T> doAsyncRetry(@Nonnull Supplier<T> supplier, int retryCount, Class<? extends Throwable>... retryException)
@SafeVarargs public static <T> Future<T> doAsyncRetry(@Nonnull Supplier<T> supplier, int retryCount, long interval, Class<? extends Throwable>... retryException)
@SafeVarargs public static <T> Future<T> doAsyncRetry(@Nonnull Supplier<T> supplier, int retryCount, long interval, boolean exponential, Class<? extends Throwable>... retryException)
@SafeVarargs public static Future<?> doAsyncRetry(@Nonnull Runnable runnable, int retryCount, Class<? extends Throwable>... retryException)
@SafeVarargs public static Future<?> doAsyncRetry(@Nonnull Runnable runnable, int retryCount, long interval, Class<? extends Throwable>... retryException)
Copyright © 2025 fossc. All rights reserved.