public class DiscardClientHandler extends SimpleChannelUpstreamHandler
ChannelHandler.Sharable
Constructor and Description |
---|
DiscardClientHandler(int messageSize) |
Modifier and Type | Method and Description |
---|---|
void |
channelConnected(ChannelHandlerContext ctx,
ChannelStateEvent e)
Invoked when a
Channel is open, bound to a local address, and
connected to a remote address. |
void |
channelInterestChanged(ChannelHandlerContext ctx,
ChannelStateEvent e)
Invoked when a
Channel 's interestOps
was changed. |
void |
exceptionCaught(ChannelHandlerContext ctx,
ExceptionEvent e)
Invoked when an exception was raised by an I/O thread or a
ChannelHandler . |
long |
getTransferredBytes() |
void |
handleUpstream(ChannelHandlerContext ctx,
ChannelEvent e)
Handles the specified upstream event.
|
void |
messageReceived(ChannelHandlerContext ctx,
MessageEvent e)
Invoked when a message object (e.g:
ChannelBuffer ) was received
from a remote peer. |
void |
writeComplete(ChannelHandlerContext ctx,
WriteCompletionEvent e)
Invoked when something was written into a
Channel . |
channelBound, channelClosed, channelDisconnected, channelOpen, channelUnbound, childChannelClosed, childChannelOpen
public long getTransferredBytes()
public void handleUpstream(ChannelHandlerContext ctx, ChannelEvent e) throws Exception
SimpleChannelUpstreamHandler
handleUpstream
in interface ChannelUpstreamHandler
handleUpstream
in class SimpleChannelUpstreamHandler
ctx
- the context object for this handlere
- the upstream event to process or interceptException
public void channelConnected(ChannelHandlerContext ctx, ChannelStateEvent e)
SimpleChannelUpstreamHandler
Channel
is open, bound to a local address, and
connected to a remote address.
channelConnected
in class SimpleChannelUpstreamHandler
public void channelInterestChanged(ChannelHandlerContext ctx, ChannelStateEvent e)
SimpleChannelUpstreamHandler
Channel
's interestOps
was changed.channelInterestChanged
in class SimpleChannelUpstreamHandler
public void messageReceived(ChannelHandlerContext ctx, MessageEvent e)
SimpleChannelUpstreamHandler
ChannelBuffer
) was received
from a remote peer.messageReceived
in class SimpleChannelUpstreamHandler
public void writeComplete(ChannelHandlerContext ctx, WriteCompletionEvent e)
SimpleChannelUpstreamHandler
Channel
.writeComplete
in class SimpleChannelUpstreamHandler
public void exceptionCaught(ChannelHandlerContext ctx, ExceptionEvent e)
SimpleChannelUpstreamHandler
ChannelHandler
.exceptionCaught
in class SimpleChannelUpstreamHandler
Copyright © 2008-2015 The Netty Project. All Rights Reserved.