examples
Class PrintCommandListener

java.lang.Object
  extended by examples.PrintCommandListener
All Implemented Interfaces:
EventListener, ProtocolCommandListener

public class PrintCommandListener
extends Object
implements ProtocolCommandListener

This is a support class for some of the example programs. It is a sample implementation of the ProtocolCommandListener interface which just prints out to a specified stream all command/reply traffic.


Constructor Summary
PrintCommandListener(PrintWriter writer)
           
 
Method Summary
 void protocolCommandSent(ProtocolCommandEvent event)
          This method is invoked by a ProtocolCommandEvent source after sending a protocol command to a server.
 void protocolReplyReceived(ProtocolCommandEvent event)
          This method is invoked by a ProtocolCommandEvent source after receiving a reply from a server.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PrintCommandListener

public PrintCommandListener(PrintWriter writer)
Method Detail

protocolCommandSent

public void protocolCommandSent(ProtocolCommandEvent event)
Description copied from interface: ProtocolCommandListener
This method is invoked by a ProtocolCommandEvent source after sending a protocol command to a server.

Specified by:
protocolCommandSent in interface ProtocolCommandListener
Parameters:
event - The ProtocolCommandEvent fired.

protocolReplyReceived

public void protocolReplyReceived(ProtocolCommandEvent event)
Description copied from interface: ProtocolCommandListener
This method is invoked by a ProtocolCommandEvent source after receiving a reply from a server.

Specified by:
protocolReplyReceived in interface ProtocolCommandListener
Parameters:
event - The ProtocolCommandEvent fired.


Copyright © 1997-2010 The Apache Software Foundation. All Rights Reserved.