|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object
|
+--java.lang.Thread
|
+--irssibot.remote.http.HttpServer
HTTP interface for remote administration of IrssiBot.
| Field Summary | |
private java.util.ArrayList |
hostsAllow
Allowed hostmasks |
private java.util.ArrayList |
hostsDeny
Disallowed hostmasks |
private static java.lang.String |
info
Module info string |
private boolean |
isRunning
Whether to keep listening to connections. |
private java.net.ServerSocket |
serverSocket
Server socket |
private static int |
SOCKET_SO_TIMEOUT
Socket timeout value (in milliseconds). |
| Fields inherited from class java.lang.Thread |
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY |
| Constructor Summary | |
HttpServer()
|
|
| Method Summary | |
void |
init(int port,
java.util.ArrayList hostsAllow,
java.util.ArrayList hostsDeny)
Initializes the server. |
void |
run()
Listens to the server socket for inbound connections. |
void |
stopServer()
Stops the server thread. |
java.lang.String |
toString()
Returns textual description. |
| Methods inherited from class java.lang.Thread |
activeCount, checkAccess, countStackFrames, currentThread, destroy, dumpStack, enumerate, getContextClassLoader, getName, getPriority, getThreadGroup, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setName, setPriority, sleep, sleep, start, stop, stop, suspend, yield |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
private static final int SOCKET_SO_TIMEOUT
private static final java.lang.String info
private java.util.ArrayList hostsAllow
private java.util.ArrayList hostsDeny
private java.net.ServerSocket serverSocket
private boolean isRunning
| Constructor Detail |
public HttpServer()
| Method Detail |
public void init(int port,
java.util.ArrayList hostsAllow,
java.util.ArrayList hostsDeny)
throws java.io.IOException
port - server port to listen tohostsAllow - allowed hostmaskshostsDeny - disallowed hostmasks
java.io.IOExceptionpublic void stopServer()
public void run()
run in interface java.lang.Runnablerun in class java.lang.Threadpublic java.lang.String toString()
toString in class java.lang.Thread
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||