com.alibaba.dubbo.remoting
Interface ChannelHandler

All Known Subinterfaces:
ChannelHandlerDelegate, ExchangeHandler
All Known Implementing Classes:
AbstractChannel, AbstractChannelHandlerDelegate, AbstractClient, AbstractEndpoint, AbstractPeer, AbstractServer, AllChannelHandler, ChannelHandlerAdapter, ChannelHandlerDispatcher, ConnectionOrderedChannelHandler, DecodeHandler, ExchangeHandlerAdapter, ExchangeHandlerDispatcher, ExecutionChannelHandler, GrizzlyClient, GrizzlyServer, HeaderExchangeHandler, HeartbeatHandler, MessageOnlyChannelHandler, MinaClient, MinaServer, MultiMessageHandler, NettyClient, NettyClient, NettyServer, NettyServer, TelnetHandlerAdapter, WrappedChannelHandler

@SPI
public interface ChannelHandler

ChannelHandler. (API, Prototype, ThreadSafe)

Author:
qian.lei, william.liangf
See Also:
Transporter.bind(com.alibaba.dubbo.common.URL, ChannelHandler), Transporter.connect(com.alibaba.dubbo.common.URL, ChannelHandler)

Method Summary
 void caught(Channel channel, Throwable exception)
          on exception caught.
 void connected(Channel channel)
          on channel connected.
 void disconnected(Channel channel)
          on channel disconnected.
 void received(Channel channel, Object message)
          on message received.
 void sent(Channel channel, Object message)
          on message sent.
 

Method Detail

connected

void connected(Channel channel)
               throws RemotingException
on channel connected.

Parameters:
channel - channel.
Throws:
RemotingException

disconnected

void disconnected(Channel channel)
                  throws RemotingException
on channel disconnected.

Parameters:
channel - channel.
Throws:
RemotingException

sent

void sent(Channel channel,
          Object message)
          throws RemotingException
on message sent.

Parameters:
channel - channel.
message - message.
Throws:
RemotingException

received

void received(Channel channel,
              Object message)
              throws RemotingException
on message received.

Parameters:
channel - channel.
message - message.
Throws:
RemotingException

caught

void caught(Channel channel,
            Throwable exception)
            throws RemotingException
on exception caught.

Parameters:
channel - channel.
exception - exception.
Throws:
RemotingException


Copyright © 2012–2017 Alibaba. All rights reserved.