rabbit.meta
Class SimpleHandler

java.lang.Object
  extended by rabbit.meta.SimpleHandler
All Implemented Interfaces:
MetaHandler
Direct Known Subclasses:
ProxyConfig, UserGetter

public abstract class SimpleHandler
extends java.lang.Object
implements MetaHandler

A base class for simple meta pages.


Constructor Summary
SimpleHandler()
          default constructor
 
Method Summary
abstract  java.lang.String getMark()
          Get the mark.
 void handle(java.io.InputStream input, MultiOutputStream output, HTTPHeader header, java.util.Properties htab, Connection con)
          handler of a MetaPage, that is a special page the proxy supports (like the status page).
abstract  void handleData(Connection con, java.lang.String data)
          Handle the user data.
abstract  void sendPage(MultiOutputStream output, Connection con)
          Send the response page.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SimpleHandler

public SimpleHandler()
default constructor

Method Detail

handle

public void handle(java.io.InputStream input,
                   MultiOutputStream output,
                   HTTPHeader header,
                   java.util.Properties htab,
                   Connection con)
handler of a MetaPage, that is a special page the proxy supports (like the status page).

Specified by:
handle in interface MetaHandler
Parameters:
input - the InputStream from the client.
output - the OutputStream to the client.
header - the http request header
htab - the supplied argument to the page (CGI-parameters).
con - the Connection that is serving the request.

getMark

public abstract java.lang.String getMark()
Get the mark.


handleData

public abstract void handleData(Connection con,
                                java.lang.String data)
Handle the user data.

Parameters:
con - the Connection doing the transaction.
data - the url decoded data.

sendPage

public abstract void sendPage(MultiOutputStream output,
                              Connection con)
Send the response page.

Parameters:
output - the stream to send the page on
con - the Connection handling the request