com.debianmirror.server
Class ServerConfig

java.lang.Object
  |
  +--com.debianmirror.server.ServerConfig

public class ServerConfig
extends java.lang.Object

Contains the information to configure the server.


Field Summary
static java.lang.String LISTENINGPORT_KEY
          The key used in the config file for the listing port
static java.lang.String NR_OF_WORKERS_KEY
          The key used in the config file for the number of workers
 
Constructor Summary
ServerConfig(java.lang.String fileName)
          Initializes the ServerConfig from a properties-file
 
Method Summary
 int getListeningPort()
          Returns the listing port specified in the config file.
 int getNrOfWorkers()
          Returns the number of workers specified in the config file.
 java.lang.String toString()
          Returns the configuration as a String.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

LISTENINGPORT_KEY

public static final java.lang.String LISTENINGPORT_KEY
The key used in the config file for the listing port

See Also:
Constant Field Values

NR_OF_WORKERS_KEY

public static final java.lang.String NR_OF_WORKERS_KEY
The key used in the config file for the number of workers

See Also:
Constant Field Values
Constructor Detail

ServerConfig

public ServerConfig(java.lang.String fileName)
Initializes the ServerConfig from a properties-file

Method Detail

getListeningPort

public int getListeningPort()
Returns the listing port specified in the config file.

Returns:
the listing port.

getNrOfWorkers

public int getNrOfWorkers()
Returns the number of workers specified in the config file.

Returns:
the number of workers.

toString

public java.lang.String toString()
Returns the configuration as a String.

Overrides:
toString in class java.lang.Object
Returns:
the configuration as a String.


Copyright © 2004, Apt-Got Group