com.debianmirror.server
Class Server

java.lang.Object
  |
  +--java.lang.Thread
        |
        +--com.debianmirror.server.Server
All Implemented Interfaces:
java.lang.Runnable

public class Server
extends java.lang.Thread

The main purpose of the Server is to get a socket from the Listener and to hand this socket to the Worker.
The Server gets the Worker by requesting one from the WorkerCache.

All configuration values are stored in the ServerConfig object.

Author:
E01 - Tobias Hertkorn, Jonas Jagerhok, Jamie Fitz-Gerald

Field Summary
 
Fields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
 
Constructor Summary
Server(ServerConfig sc)
          Creates a new Server with the given ServerConfig.
 
Method Summary
 void run()
          Starts the thread.
 
Methods inherited from class java.lang.Thread
activeCount, checkAccess, countStackFrames, currentThread, destroy, dumpStack, enumerate, getContextClassLoader, getName, getPriority, getThreadGroup, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setName, setPriority, sleep, sleep, start, stop, stop, suspend, toString, yield
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Server

public Server(ServerConfig sc)
       throws java.io.IOException

Creates a new Server with the given ServerConfig.
It starts the Listener and the WorkerCache.

Throws:
IOException - gets thrown.
Method Detail

run

public void run()

Starts the thread.
Basicly calls the serveLoop() method

Specified by:
run in interface java.lang.Runnable
Overrides:
run in class java.lang.Thread


Copyright © 2004, Apt-Got Group