rabbit.filter
Class HttpSnoop

java.lang.Object
  extended by rabbit.filter.HttpSnoop
All Implemented Interfaces:
HttpFilter

public class HttpSnoop
extends Object
implements HttpFilter

This is a class that prints the Http headers on the standard out stream.


Constructor Summary
HttpSnoop()
           
 
Method Summary
 HttpHeader doHttpInFiltering(SocketChannel socket, HttpHeader header, Connection con)
          test if a socket/header combination is valid or return a new HttpHeader.
 HttpHeader doHttpOutFiltering(SocketChannel socket, HttpHeader header, Connection con)
          test if a socket/header combination is valid or return a new HttpHeader.
 void setup(Logger logger, SProperties properties)
          Setup this class with the given properties.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HttpSnoop

public HttpSnoop()
Method Detail

doHttpInFiltering

public HttpHeader doHttpInFiltering(SocketChannel socket,
                                    HttpHeader header,
                                    Connection con)
test if a socket/header combination is valid or return a new HttpHeader.

Specified by:
doHttpInFiltering in interface HttpFilter
Parameters:
socket - the SocketChannel that made the request.
header - the actual request made.
con - the Connection handling the request.
Returns:
This method always returns null.

doHttpOutFiltering

public HttpHeader doHttpOutFiltering(SocketChannel socket,
                                     HttpHeader header,
                                     Connection con)
test if a socket/header combination is valid or return a new HttpHeader.

Specified by:
doHttpOutFiltering in interface HttpFilter
Parameters:
socket - the Socket that made the request.
header - the actual request made.
con - the Connection handling the request.
Returns:
This method always returns null.

setup

public void setup(Logger logger,
                  SProperties properties)
Setup this class with the given properties.

Specified by:
setup in interface HttpFilter
Parameters:
logger - the Logger to output errors/warnings on.
properties - the new configuration of this class.