Package org.jboss.netty.handler.timeout
Class IdleStateAwareChannelUpstreamHandler
- java.lang.Object
-
- org.jboss.netty.channel.SimpleChannelUpstreamHandler
-
- org.jboss.netty.handler.timeout.IdleStateAwareChannelUpstreamHandler
-
- All Implemented Interfaces:
ChannelHandler
,ChannelUpstreamHandler
public class IdleStateAwareChannelUpstreamHandler extends SimpleChannelUpstreamHandler
An extendedSimpleChannelUpstreamHandler
that adds the handler method for anIdleStateEvent
.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.jboss.netty.channel.ChannelHandler
ChannelHandler.Sharable
-
-
Constructor Summary
Constructors Constructor Description IdleStateAwareChannelUpstreamHandler()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
channelIdle(ChannelHandlerContext ctx, IdleStateEvent e)
Invoked when aChannel
has been idle for a while.void
handleUpstream(ChannelHandlerContext ctx, ChannelEvent e)
Handles the specified upstream event.-
Methods inherited from class org.jboss.netty.channel.SimpleChannelUpstreamHandler
channelBound, channelClosed, channelConnected, channelDisconnected, channelInterestChanged, channelOpen, channelUnbound, childChannelClosed, childChannelOpen, exceptionCaught, messageReceived, writeComplete
-
-
-
-
Method Detail
-
handleUpstream
public void handleUpstream(ChannelHandlerContext ctx, ChannelEvent e) throws Exception
Description copied from class:SimpleChannelUpstreamHandler
Handles the specified upstream event. Down-casts the received upstream event into more meaningful sub-type event and calls an appropriate handler method with the down-casted event.- Specified by:
handleUpstream
in interfaceChannelUpstreamHandler
- Overrides:
handleUpstream
in classSimpleChannelUpstreamHandler
- Parameters:
ctx
- the context object for this handlere
- the upstream event to process or intercept- Throws:
Exception
-
channelIdle
public void channelIdle(ChannelHandlerContext ctx, IdleStateEvent e) throws Exception
Invoked when aChannel
has been idle for a while.- Throws:
Exception
-
-