/*
** j###t ########## #### ####
** j###t ########## #### ####
** j###T "###L J###"
** ######P' ########## #########
** ######k, ########## T######T
** ####~###L ####
** #### q###L ########## .#####
** #### \###L ########## #####"
*/
package key.web;
import java.net.*;
import java.io.*;
import java.util.Date;
import java.util.Vector;
import java.util.StringTokenizer;
import com.mortbay.Util.InetAddrPort;
import com.mortbay.HTTP.Configure.BaseConfiguration;
import com.mortbay.HTTP.PathMap;
import com.mortbay.HTTP.HttpHandler;
import com.mortbay.HTTP.HttpServer;
import com.mortbay.HTTP.Handler.*;
/**
* This class is a thread which opens and binds a port,
* creating new instances of 'InteractiveConnectionion' to
* deal with each connection request that comes in.
*/
public class WWWDaemon extends key.Daemon
{
private static final long serialVersionUID=-1359963406925714554L;
transient com.mortbay.Jetty.Server www;
transient HttpServer server;
public WWWDaemon()
{
}
public void start()
{
if( www == null )
{
try
{
String args[] = {"etc/keyweb.prp"};
com.mortbay.Jetty.Server.main( args );
}
catch( Exception e )
{
e.printStackTrace();
return;
}
}
/*
//if( server == null )
//server = new HttpServer();
try
{
//server.configure( www );
www.start();
}
catch( Exception e )
{
key.Log.error( e );
}
*/
}
public void run()
{
}
public void stop()
{
//if( server != null )
//server.close();
super.stop();
}
}