|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sf.ooweb.http.AbstractServer
public abstract class AbstractServer
AbstractServer is a superclass for Ooweb servers allowing subclasses to build on existing HTTP server architectures.
Field Summary | |
---|---|
protected static java.lang.String |
DEFAULT_QUIP
|
protected java.util.logging.Logger |
logger
|
protected static java.lang.String |
QUIP_FILE
|
protected static java.util.List<java.lang.String> |
quipList
|
Constructor Summary | |
---|---|
AbstractServer()
|
Method Summary | |
---|---|
void |
addController(java.lang.Object object)
Register a controller. |
static Cache |
getCache()
return the cache implementation in use |
protected java.lang.String |
getQuip()
Returns a random quip for the startup message. |
static Registry |
getRegistry()
Return the object registry |
protected static Cache |
initialiseCache()
subclasses should override to provide a concrete inplementation of the Cache interface that will be used by this server. |
void |
setControllers(java.util.List controllers)
Register a List of controllers, each of which must carry the @Controller annotation at the class level |
void |
start()
subclasses usually will want to override this method to actually start the server. |
void |
stop()
subclasses can optionally override the stop method to shutdown the server gracefully. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected final java.util.logging.Logger logger
protected static final java.lang.String DEFAULT_QUIP
protected static final java.lang.String QUIP_FILE
protected static final java.util.List<java.lang.String> quipList
Constructor Detail |
---|
public AbstractServer()
Method Detail |
---|
public void start() throws java.lang.Exception
start
in interface Server
java.lang.Exception
Server.start()
public void stop()
stop
in interface Server
Server.stop()
public static final Cache getCache()
protected static Cache initialiseCache()
public static Registry getRegistry()
public void setControllers(java.util.List controllers)
setControllers
in interface Server
Server.setControllers(java.util.List)
public void addController(java.lang.Object object)
addController
in interface Server
protected java.lang.String getQuip()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |