Class ChannelFutures
- java.lang.Object
-
- org.apache.pulsar.common.util.netty.ChannelFutures
-
public class ChannelFutures extends java.lang.ObjectStatic utility methods for operating onChannelFutures.
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static java.util.concurrent.CompletableFuture<io.netty.channel.Channel>toCompletableFuture(io.netty.channel.ChannelFuture channelFuture)Convert aChannelFutureinto aCompletableFuture.
-
-
-
Method Detail
-
toCompletableFuture
public static java.util.concurrent.CompletableFuture<io.netty.channel.Channel> toCompletableFuture(io.netty.channel.ChannelFuture channelFuture)
Convert aChannelFutureinto aCompletableFuture.- Parameters:
channelFuture- theChannelFuture- Returns:
- a
CompletableFuturethat completes successfully when the channelFuture completes successfully, and completes exceptionally if the channelFuture completes with aThrowable
-
-