DBAbstract API Documentation

ro.raducora.connection.server.tcp
Class ServerThread

java.lang.Object
  |
  +--java.lang.Thread
        |
        +--ro.raducora.connection.server.tcp.ServerThread
All Implemented Interfaces:
java.lang.Runnable

public class ServerThread
extends java.lang.Thread

Author:
Radu Coravu
A Server Thread serving one client

Field Summary
 
Fields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
 
Constructor Summary
ServerThread(java.io.ObjectOutputStream output, java.io.ObjectInputStream input, boolean gzipOutput, boolean directConnection, AdapterManager adapterManager)
          Constructor.
 
Method Summary
 void run()
          Runs the server thread.
static void setMaxNoConnections(int maxNo)
          Sets the maximum number of accepted connections
 void stopThread()
          Elegantly stops 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

ServerThread

public ServerThread(java.io.ObjectOutputStream output,
                    java.io.ObjectInputStream input,
                    boolean gzipOutput,
                    boolean directConnection,
                    AdapterManager adapterManager)
Constructor.

Parameters:
output - the ObjectOutputStream
input - the ObjectInputStream
Method Detail

stopThread

public void stopThread()
Elegantly stops the thread


setMaxNoConnections

public static void setMaxNoConnections(int maxNo)
Sets the maximum number of accepted connections

Parameters:
maxNo - the max no of allowed server threads

run

public void run()
Runs the server thread.

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

DBAbstract API Documentation

© Copyright Radu Coravu 2002 - 2004.