Package com.linkedin.alpini.netty4.misc
Class NettyUtils
- java.lang.Object
-
- com.linkedin.alpini.netty4.misc.NettyUtils
-
public class NettyUtils extends java.lang.ObjectCreated by acurtis on 3/30/17.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classNettyUtils.Modestatic classNettyUtils.ReadMode
-
Field Summary
Fields Modifier and Type Field Description static io.netty.util.AttributeKey<io.netty.util.concurrent.EventExecutorGroup>EXECUTOR_GROUP_ATTRIBUTE_KEY
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static java.lang.Class<? extends io.netty.channel.socket.DatagramChannel>datagramChannel()static io.netty.util.concurrent.EventExecutorGroupexecutorGroup(io.netty.channel.Channel channel)static io.netty.util.concurrent.EventExecutorGroupexecutorGroup(io.netty.channel.ChannelPipeline pipeline)static booleanisTrue(io.netty.util.AttributeMap map, io.netty.util.AttributeKey<java.lang.Boolean> key)static NettyUtils.Modemode()static io.netty.channel.EventLoopGroupnewEventLoopGroup(int nThreads, java.util.concurrent.Executor executor)static io.netty.channel.EventLoopGroupnewEventLoopGroup(int nThreads, java.util.concurrent.ThreadFactory threadFactory)static io.netty.buffer.ByteBufread(io.netty.buffer.ByteBuf in, int length)static NettyUtils.ReadModereadMode()static java.lang.Class<? extends io.netty.channel.socket.ServerSocketChannel>serverSocketChannel()static voidsetMode(NettyUtils.Mode mode)static voidsetMode(java.lang.String mode)static voidsetReadMode(NettyUtils.ReadMode mode)static voidsetReadMode(java.lang.String mode)static java.lang.Class<? extends io.netty.channel.socket.SocketChannel>socketChannel()
-
-
-
Method Detail
-
setMode
public static void setMode(java.lang.String mode)
-
setMode
public static void setMode(NettyUtils.Mode mode)
-
mode
@Nonnull public static NettyUtils.Mode mode()
-
setReadMode
public static void setReadMode(java.lang.String mode)
-
setReadMode
public static void setReadMode(NettyUtils.ReadMode mode)
-
readMode
@Nonnull public static NettyUtils.ReadMode readMode()
-
read
public static io.netty.buffer.ByteBuf read(io.netty.buffer.ByteBuf in, int length)
-
newEventLoopGroup
public static io.netty.channel.EventLoopGroup newEventLoopGroup(int nThreads, java.util.concurrent.ThreadFactory threadFactory)
-
newEventLoopGroup
public static io.netty.channel.EventLoopGroup newEventLoopGroup(int nThreads, java.util.concurrent.Executor executor)
-
socketChannel
public static java.lang.Class<? extends io.netty.channel.socket.SocketChannel> socketChannel()
-
serverSocketChannel
public static java.lang.Class<? extends io.netty.channel.socket.ServerSocketChannel> serverSocketChannel()
-
datagramChannel
public static java.lang.Class<? extends io.netty.channel.socket.DatagramChannel> datagramChannel()
-
executorGroup
public static io.netty.util.concurrent.EventExecutorGroup executorGroup(io.netty.channel.Channel channel)
-
executorGroup
public static io.netty.util.concurrent.EventExecutorGroup executorGroup(io.netty.channel.ChannelPipeline pipeline)
-
isTrue
public static boolean isTrue(io.netty.util.AttributeMap map, io.netty.util.AttributeKey<java.lang.Boolean> key)
-
-