Package org.drasyl.util
Class FutureUtil
- java.lang.Object
-
- org.drasyl.util.FutureUtil
-
public final class FutureUtil extends Object
Utility class for future-related operations.
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static <T> CompletableFuture<T>
toFuture(io.netty.util.concurrent.Future<T> future)
Translates the NettyFuture
to aCompletableFuture
.
-
-
-
Method Detail
-
toFuture
public static <T> CompletableFuture<T> toFuture(io.netty.util.concurrent.Future<T> future)
Translates the NettyFuture
to aCompletableFuture
.- Type Parameters:
T
- The result type of the future- Parameters:
future
- The future to be translated- Returns:
- The translated
CompletableFuture
-
-