|
JavaGantt 2011.1 API | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objecteu.beesoft.gaia.server.AbstractServer
eu.beesoft.gaia.swing.server.ApplicationServer
public class ApplicationServer
This is a server to process SwingClient requests. It manages an
instances of Application and redirects requests to the appropriate
instance (accodring to client / application id).
| Constructor Summary | |
|---|---|
ApplicationServer()
Creates a new instance of application server. |
|
| Method Summary | |
|---|---|
protected Application |
createApplication(ApplicationRequest request)
Creates a new application as an instance of the class which name is equal to the request's action. |
void |
finishApplication(Application application)
Removes given application instance from internal map, so it cannot be invoked from client and it does not take a space in memory. |
static void |
main(java.lang.String[] arg)
Creates a new instance of ApplicationServer and starts it. |
protected void |
process(java.net.Socket socket)
Implementation of processs() method from
AbstractServer. |
protected ApplicationResponse |
processRequest(ApplicationRequest request,
Application application)
Invokes request processing on given application. |
| Methods inherited from class eu.beesoft.gaia.server.AbstractServer |
|---|
getLog, getMaxThreads, getMinThreads, getPort, isRunning, setMaxThreads, setMaxThreads, setMinThreads, setMinThreads, setPort, setPort, start, stop |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ApplicationServer()
| Method Detail |
|---|
protected void process(java.net.Socket socket)
processs() method from
AbstractServer. It covers all communication with
SwingClient. It transforms received data to
ApplicationRequest and delivers it to referenced
Application instance to process.
process in class AbstractServersocket - - socket to communicateprotected Application createApplication(ApplicationRequest request)
process(Socket) if there is no application instance found for
incomming client (application) id.
request - - request to process
protected ApplicationResponse processRequest(ApplicationRequest request,
Application application)
process(Socket). Override this method if you need
pre-process or post-process the request processing.
request - - request to processapplication - - application which should process given request
public void finishApplication(Application application)
Application.timedOut() method).
finishApplication in interface ApplicationContainerapplication - - application to finishpublic static void main(java.lang.String[] arg)
ApplicationServer and starts it.
|
JavaGantt 2011.1 API | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||