org.jetbrains.io.SimpleChannelInboundHandlerAdapter Maven / Gradle / Ivy
package org.jetbrains.io;
import io.netty.channel.ChannelHandlerContext;
import io.netty.channel.SimpleChannelInboundHandler;
/**
* You should use this class instead of {@link SimpleChannelInboundHandler} to simplify migration to netty 5 in the future.
*/
public abstract class SimpleChannelInboundHandlerAdapter extends SimpleChannelInboundHandler {
protected SimpleChannelInboundHandlerAdapter() {
super(true);
}
protected SimpleChannelInboundHandlerAdapter(boolean autoRelease) {
super(autoRelease);
}
@Override
protected final void channelRead0(ChannelHandlerContext ctx, I message) throws Exception {
messageReceived(ctx, message);
}
protected abstract void messageReceived(ChannelHandlerContext context, I message) throws Exception;
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy