|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.apache.avalon.framework.logger.AbstractLogEnabled
org.apache.excalibur.instrument.AbstractLogEnabledInstrumentable
org.apache.excalibur.instrument.manager.http.server.AbstractLogEnabledInstrumentableStartable
org.apache.excalibur.instrument.manager.http.server.AbstractSocketServer
org.apache.excalibur.instrument.manager.http.server.HTTPServer
| Field Summary |
| Fields inherited from interface org.apache.excalibur.instrument.Instrumentable |
EMPTY_INSTRUMENT_ARRAY, EMPTY_INSTRUMENTABLE_ARRAY |
| Constructor Summary | |
HTTPServer(int port,
java.net.InetAddress bindAddress)
Creates a new HTTPServer. |
|
| Method Summary | |
protected int |
getSoTimeout()
|
protected void |
handleSocket(java.net.Socket socket)
Handle a newly connected socket. |
boolean |
isStopping()
Returns true when the component is in the process of being stopped. |
void |
registerHandler(HTTPURLHandler handler)
Registers a new HTTP URL Handler with the server. |
void |
run()
Run method which is responsible for launching the runner method and handling the shutdown cycle. |
protected void |
runner()
Runner method that will be called when the component is started. |
void |
setAccessLogFile(java.lang.String accessLogFile)
Access log file name. |
void |
setParameter(java.util.Map params,
java.lang.String param,
java.lang.String value)
|
void |
start()
Starts the runner thread. |
void |
stop()
Stops the server. |
protected void |
stopRunner()
Called when the component is being stopped, the isStopping method will always return true when this method is called. |
| Methods inherited from class org.apache.excalibur.instrument.AbstractLogEnabledInstrumentable |
addChildInstrumentable, addInstrument, getChildInstrumentables, getInstrumentableName, getInstruments, setInstrumentableName |
| Methods inherited from class org.apache.avalon.framework.logger.AbstractLogEnabled |
enableLogging, getLogger, setupLogger, setupLogger, setupLogger |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public HTTPServer(int port,
java.net.InetAddress bindAddress)
port - The port on which the server will listen.bindAddress - The address on which the server will listen for
connections.| Method Detail |
public void stop()
throws java.lang.Exception
java.lang.Exception - If there are any problems stopping the component.protected void handleSocket(java.net.Socket socket)
socket - Newly connected Socket to be handled.public void setAccessLogFile(java.lang.String accessLogFile)
accessLogFile - Name of the log file or null if disabled.public void registerHandler(HTTPURLHandler handler)
handler - The handler to register.
public void setParameter(java.util.Map params,
java.lang.String param,
java.lang.String value)
public void start()
throws java.lang.Exception
java.lang.Exception - If there are any problems.
protected void stopRunner()
throws java.lang.Exception
java.lang.Exception - If there are any problemsprotected void runner()
protected int getSoTimeout()
public void run()
run in interface java.lang.Runnablepublic boolean isStopping()
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||