public abstract class Futures extends Object
| 限定符和类型 | 方法和说明 |
|---|---|
static <T> CompletableFuture<T> |
failed(Throwable throwable)
Create a
CompletableFuture that is completed exceptionally with
throwable. |
static <T> T |
join(CompletableFuture<T> future)
Synchronizes a
CompletableFuture result by waiting until the future is complete. |
public static <T> CompletableFuture<T> failed(Throwable throwable)
CompletableFuture that is completed exceptionally with
throwable.throwable - must not be null.CompletableFuture.public static <T> T join(CompletableFuture<T> future)
CompletableFuture result by waiting until the future is complete.future - must not be null.Copyright © 2020. All rights reserved.