gecco.server.core
Class ReferenceHolder

java.lang.Object
  |
  +--gecco.server.core.ReferenceHolder

public class ReferenceHolder
extends Object

This class holds references to all important modules of the server. The modules can then get references to the other modules via this class.

Author:
Henrik Bäärnhielm, Karl Hasselström, Henrik Hägerström.

Field Summary
private static ActionProcessor actionProcessor
          Description of the Field
private static AutomatonMap automatonMap
          Description of the Field
private static Client comClient
          Description of the Field
private static Server comServer
          Description of the Field
static PrintWriter err
          Standard error output
private static ClassLoader gameClassLoader
          This is the ClassLoader that is used to load classes from the jar file making up a particular game.
static BufferedReader in
          Standard input
private static LogManager logManager
          Description of the Field
static PrintWriter out
          Standard output
private static QManager qManager
          Description of the Field
private static UnitManager unitManager
          Description of the Field
private static VisibilityManager visibilityManager
          Description of the Field
 
Constructor Summary
ReferenceHolder()
           
 
Method Summary
static ActionProcessor getActionProcessor()
          Gets the ActionProcessor attribute of the ReferenceHolder class
static AutomatonMap getAutomatonMap()
          Gets the AutomatonMap attribute of the ReferenceHolder class
static Client getComClient()
          Gets the ComClient attribute of the ReferenceHolder class
static Server getComServer()
          Gets the ComServer attribute of the ReferenceHolder class
static ClassLoader getGameClassLoader()
           
static LogManager getLogManager()
          Gets the LogManager attribute of the ReferenceHolder class
static QManager getQManager()
          Gets the QManager attribute of the ReferenceHolder class
static UnitManager getUnitManager()
          Gets the UnitManager attribute of the ReferenceHolder class
static VisibilityManager getVisibilityManager()
          Gets the VisibilityManager attribute of the ReferenceHolder class
static void setActionProcessor(ActionProcessor _actionProcessor)
          Sets the ActionProcessor attribute of the ReferenceHolder class
static void setAutomatonMap(AutomatonMap map)
          Sets the AutomatonMap attribute of the ReferenceHolder class
static void setComClient(Client _comClient)
          Sets the ComClient attribute of the ReferenceHolder class
static void setComServer(Server _comServer)
          Sets the ComServer attribute of the ReferenceHolder class
static void setGameClassLoader(ClassLoader loader)
           
static void setLogManager(LogManager _logManager)
          Sets the LogManager attribute of the ReferenceHolder class
static void setQManager(QManager _qManager)
          Sets the QManager attribute of the ReferenceHolder class
static void setUnitManager(UnitManager _unitManager)
          Sets the UnitManager attribute of the ReferenceHolder class
static void setVisibilityManager(VisibilityManager _visibilityManager)
          Sets the VisibilityManager attribute of the ReferenceHolder class
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

unitManager

private static UnitManager unitManager
Description of the Field

qManager

private static QManager qManager
Description of the Field

visibilityManager

private static VisibilityManager visibilityManager
Description of the Field

logManager

private static LogManager logManager
Description of the Field

actionProcessor

private static ActionProcessor actionProcessor
Description of the Field

automatonMap

private static AutomatonMap automatonMap
Description of the Field

comClient

private static Client comClient
Description of the Field

comServer

private static Server comServer
Description of the Field

gameClassLoader

private static ClassLoader gameClassLoader
This is the ClassLoader that is used to load classes from the jar file making up a particular game.

in

public static BufferedReader in
Standard input

out

public static PrintWriter out
Standard output

err

public static PrintWriter err
Standard error output
Constructor Detail

ReferenceHolder

public ReferenceHolder()
Method Detail

setAutomatonMap

public static void setAutomatonMap(AutomatonMap map)
Sets the AutomatonMap attribute of the ReferenceHolder class
Parameters:
map - The new AutomatonMap value

setLogManager

public static void setLogManager(LogManager _logManager)
Sets the LogManager attribute of the ReferenceHolder class
Parameters:
_logManager - The new LogManager value

setActionProcessor

public static void setActionProcessor(ActionProcessor _actionProcessor)
Sets the ActionProcessor attribute of the ReferenceHolder class
Parameters:
_actionProcessor - The new ActionProcessor value

setUnitManager

public static void setUnitManager(UnitManager _unitManager)
Sets the UnitManager attribute of the ReferenceHolder class
Parameters:
_unitManager - The new UnitManager value

setQManager

public static void setQManager(QManager _qManager)
Sets the QManager attribute of the ReferenceHolder class
Parameters:
_qManager - The new QManager value

setComClient

public static void setComClient(Client _comClient)
Sets the ComClient attribute of the ReferenceHolder class
Parameters:
_comClient - The new ComClient value

setComServer

public static void setComServer(Server _comServer)
Sets the ComServer attribute of the ReferenceHolder class
Parameters:
_comServer - The new ComServer value

setVisibilityManager

public static void setVisibilityManager(VisibilityManager _visibilityManager)
Sets the VisibilityManager attribute of the ReferenceHolder class
Parameters:
_visibilityManager - The new VisibilityManager value

setGameClassLoader

public static void setGameClassLoader(ClassLoader loader)

getAutomatonMap

public static AutomatonMap getAutomatonMap()
Gets the AutomatonMap attribute of the ReferenceHolder class
Returns:
The AutomatonMap value

getLogManager

public static LogManager getLogManager()
Gets the LogManager attribute of the ReferenceHolder class
Returns:
The LogManager value

getActionProcessor

public static ActionProcessor getActionProcessor()
Gets the ActionProcessor attribute of the ReferenceHolder class
Returns:
The ActionProcessor value

getUnitManager

public static UnitManager getUnitManager()
Gets the UnitManager attribute of the ReferenceHolder class
Returns:
The UnitManager value

getQManager

public static QManager getQManager()
Gets the QManager attribute of the ReferenceHolder class
Returns:
The QManager value

getComClient

public static Client getComClient()
Gets the ComClient attribute of the ReferenceHolder class
Returns:
The ComClient value

getComServer

public static Server getComServer()
Gets the ComServer attribute of the ReferenceHolder class
Returns:
The ComServer value

getVisibilityManager

public static VisibilityManager getVisibilityManager()
Gets the VisibilityManager attribute of the ReferenceHolder class
Returns:
The VisibilityManager value

getGameClassLoader

public static ClassLoader getGameClassLoader()