List of usage examples for io.netty.channel ChannelInboundHandlerAdapter subclass-usage
From source file com.example.echo.EchoServerHandler.java
@Slf4j public class EchoServerHandler extends ChannelInboundHandlerAdapter { @Override public void channelRead(final ChannelHandlerContext ctx, final Object msg) { final ByteBuf byteBuf = (ByteBuf) msg;
From source file com.example.http.hello.HttpHelloServerHandler.java
@Slf4j public class HttpHelloServerHandler extends ChannelInboundHandlerAdapter { private static final byte[] CONTENT = "Hello ( )?".getBytes(StandardCharsets.UTF_8); private final AtomicInteger counter = new AtomicInteger(0);
From source file com.example.pojo.client.ServerTimeClientHandler.java
@Slf4j public class ServerTimeClientHandler extends ChannelInboundHandlerAdapter { @Override public void channelRead(final ChannelHandlerContext ctx, final Object msg) { final ServerTime serverTime = (ServerTime) msg;
From source file com.example.pojo.server.ServerTimeServerHandler.java
@Slf4j public class ServerTimeServerHandler extends ChannelInboundHandlerAdapter { private final ZoneOffset offset = ZoneOffset.UTC; @Override
From source file com.example.spring.boot.netty.TcpClientHandler.java
public class TcpClientHandler extends ChannelInboundHandlerAdapter { public static final String MSG = "123\r\n"; private final TcpClient tcpClient; public TcpClientHandler(TcpClient tcpClient) {
From source file com.example.spring.boot.netty.TcpServerHandler.java
@ChannelHandler.Sharable public class TcpServerHandler extends ChannelInboundHandlerAdapter { private Timer timer = new Timer(); private AtomicInteger connNum = new AtomicInteger(); private AtomicInteger msgNum = new AtomicInteger();
From source file com.example.time.client.TimeClientHandler.java
@Slf4j public class TimeClientHandler extends ChannelInboundHandlerAdapter { @Override public void channelRead(final ChannelHandlerContext ctx, final Object msg) { final ByteBuf byteBuf = (ByteBuf) msg;
From source file com.example.time.server.TimeServerHandler.java
@Slf4j public class TimeServerHandler extends ChannelInboundHandlerAdapter { private final ZoneId zoneId = ZoneId.of("UTC"); @Override
From source file com.example.time1.client.FragmentedTimeClientHandler.java
@Slf4j public class FragmentedTimeClientHandler extends ChannelInboundHandlerAdapter { private ByteBuf byteBuf; // - handlerAdded
From source file com.example.time2.LoggingTimeHandler.java
@Slf4j public class LoggingTimeHandler extends ChannelInboundHandlerAdapter { @Override public void channelRead(final ChannelHandlerContext ctx, final Object msg) { try (final GracefulShutdown ignored = GracefulShutdown.gracefulShutdown(ctx::close)) {