org.jboss.netty.example.uptime
Class UptimeClientHandler
java.lang.Object
org.jboss.netty.channel.SimpleChannelUpstreamHandler
org.jboss.netty.example.uptime.UptimeClientHandler
- All Implemented Interfaces:
- ChannelHandler, ChannelUpstreamHandler
public class UptimeClientHandler
- extends SimpleChannelUpstreamHandler
Keep reconnecting to the server while printing out the current uptime and
connection attempt status.
- Version:
- $Rev: 2189 $, $Date: 2010-02-19 18:02:57 +0900 (Fri, 19 Feb 2010) $
- Author:
- The Netty Project, Trustin Lee
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
UptimeClientHandler
public UptimeClientHandler(ClientBootstrap bootstrap,
Timer timer)
channelDisconnected
public void channelDisconnected(ChannelHandlerContext ctx,
ChannelStateEvent e)
- Description copied from class:
SimpleChannelUpstreamHandler
- Invoked when a
Channel
was disconnected from its remote peer.
- Overrides:
channelDisconnected
in class SimpleChannelUpstreamHandler
channelClosed
public void channelClosed(ChannelHandlerContext ctx,
ChannelStateEvent e)
- Description copied from class:
SimpleChannelUpstreamHandler
- Invoked when a
Channel
was closed and all its related resources
were released.
- Overrides:
channelClosed
in class SimpleChannelUpstreamHandler
channelConnected
public void channelConnected(ChannelHandlerContext ctx,
ChannelStateEvent e)
- Description copied from class:
SimpleChannelUpstreamHandler
- Invoked when a
Channel
is open, bound to a local address, and
connected to a remote address.
- Overrides:
channelConnected
in class SimpleChannelUpstreamHandler
exceptionCaught
public void exceptionCaught(ChannelHandlerContext ctx,
ExceptionEvent e)
- Description copied from class:
SimpleChannelUpstreamHandler
- Invoked when an exception was raised by an I/O thread or a
ChannelHandler
.
- Overrides:
exceptionCaught
in class SimpleChannelUpstreamHandler
Copyright © 2008-2011 JBoss, a division of Red Hat, Inc.. All Rights Reserved.