|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.sf.beep4j.ext.ChannelHandlerAdapter
public abstract class ChannelHandlerAdapter
Base implementation for ChannelHandler implementors. Implement the remaining unimplemented methods and override the methods you deem necessary.
| Constructor Summary | |
|---|---|
ChannelHandlerAdapter()
|
|
| Method Summary | |
|---|---|
void |
channelClosed()
Notifies this handler that the channel has been closed. |
void |
channelCloseRequested(CloseChannelRequest request)
Notifies this handler that the remote peer requested to close the channel associated with this handler. |
void |
channelOpened(Channel channel)
Notifies this handler that the channel has been successfully opened. |
void |
channelStartFailed(int code,
java.lang.String message)
This method ignores this event. |
protected Channel |
getChannel()
Gets the channel object set by the channelOpened(Channel) method. |
void |
messageReceived(Message message,
Reply reply)
Notifies this handler that a message has been received. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ChannelHandlerAdapter()
| Method Detail |
|---|
protected Channel getChannel()
channelOpened(Channel) method.
public void channelStartFailed(int code,
java.lang.String message)
channelStartFailed in interface ChannelHandlercode - the reply codemessage - the diagnostic messagepublic void channelOpened(Channel channel)
getChannel() method.
channelOpened in interface ChannelHandlerchannel - the Channel object
public void messageReceived(Message message,
Reply reply)
messageReceived in interface ChannelHandlermessage - the received messagereply - the reply that can be used to send a replypublic void channelCloseRequested(CloseChannelRequest request)
channelCloseRequested in interface ChannelHandlerrequest - the request to be declined or acceptedpublic void channelClosed()
channelClosed in interface ChannelHandler
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||