scone.proxy
Class GeneralResourceGenerator

java.lang.Object
  extended by HttpGenerator
      extended by scone.proxy.GeneralResourceGenerator

public class GeneralResourceGenerator
extends HttpGenerator

This meg is able to return documents to the browser.
It maps web - paths to filesystem - paths. Use addPath() to add a new mapping

Author:
Harald Weinreich, Volkert Buchmann

Field Summary
protected static java.util.Hashtable paths
           
 
Constructor Summary
GeneralResourceGenerator()
           
 
Method Summary
static void addPath(java.lang.String web, java.lang.String fileSystem)
          adds a new mapping to the GeneralResourceGenerator class.
protected  java.lang.String getContentType(java.lang.String ext)
           
 void handleRequest(RequestEvent e)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

paths

protected static java.util.Hashtable paths
Constructor Detail

GeneralResourceGenerator

public GeneralResourceGenerator()
Method Detail

handleRequest

public void handleRequest(RequestEvent e)
                   throws RequestRejectedException
Throws:
RequestRejectedException

addPath

public static void addPath(java.lang.String web,
                           java.lang.String fileSystem)
adds a new mapping to the GeneralResourceGenerator class.

Parameters:
web - the web path e.g. "http://_scone/"
fielSystem - the local path e.g. "c:\anywhere\"

getContentType

protected java.lang.String getContentType(java.lang.String ext)