amber.server.manager.connection
Class ListenerThread

java.lang.Object
  |
  +--java.lang.Thread
        |
        +--amber.server.Listener
              |
              +--amber.server.manager.connection.ListenerThread
All Implemented Interfaces:
java.lang.Runnable

public class ListenerThread
extends Listener

Thread to deal with the incoming connections of login packets. This thread waits for incomimg connections and adds them to the login thread for processing.

Version:
1.0.0
Author:
Dr. David J. Knowles
See Also:
Listener, ConnectionManager, LoginThread

Fields inherited from class amber.server.Listener
AdministrationConnection, connectionNames, DefaultNumberPendingConnections, listener, loggingFile, NormalConnection, numberPendingConnections, operating, portNumber, receiver, SecureConnection
 
Fields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
 
Constructor Summary
ListenerThread(ConnectionManager parent, int portNumber, Log loggingFile, java.lang.String threadName, int type)
          Construct the thread, with it's parent class so it may pass back messages.
ListenerThread(ConnectionManager parent, int portNumber, Log loggingFile, java.lang.String threadName, int type, int pendingAllowed)
          Construct the thread, with it's parent class so it may pass back messages.
 
Method Summary
 void terminate()
          This function causes the flag to be set terminating this thread.
 
Methods inherited from class amber.server.Listener
getType, getTypeString, run, setType
 
Methods inherited from class java.lang.Thread
activeCount, checkAccess, countStackFrames, currentThread, destroy, dumpStack, enumerate, getContextClassLoader, getName, getPriority, getThreadGroup, 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

ListenerThread

public ListenerThread(ConnectionManager parent,
                      int portNumber,
                      Log loggingFile,
                      java.lang.String threadName,
                      int type)
               throws ManagerException
Construct the thread, with it's parent class so it may pass back messages.
Parameters:
parent - ConnectionManager handle to the parent manager.
portNumber - int containing the port number to listen on.
loggingFile - Log object to log messages on.
threadName - String containing the name of this thread.
type - int containing the type of listener this is. This matches the constants in this class.
certificate - RSAKey containing the encryption certificate. This is required for secure connections.
Throws:
ManagerException - should there be an error initialising the thread.

ListenerThread

public ListenerThread(ConnectionManager parent,
                      int portNumber,
                      Log loggingFile,
                      java.lang.String threadName,
                      int type,
                      int pendingAllowed)
               throws ManagerException
Construct the thread, with it's parent class so it may pass back messages.
Parameters:
parent - ConnectionManager handle to the parent manager.
portNumber - int containing the port number to listen on.
loggingFile - Log object to log messages on.
threadName - String containing the name of this thread.
type - int containing the type of listener this is. This matches the constants in this class.
certificate - RSAKey containing the encryption certificate. This is required for secure connections.
pendingAllowed - int number of pending connections the listener will allow before refusing connections.
Throws:
ManagerException - should there be an error initialising the thread.
Method Detail

terminate

public void terminate()
This function causes the flag to be set terminating this thread.
Overrides:
terminate in class Listener


Copyright © 2002 Clearfield Research Ltd. All Rights Reserved.