Modifier and Type | Field | Description |
---|---|---|
static char |
MAIN_HOST |
for multi-host systems, the thread code denoting the main/first mud host
|
static long |
TIME_SAVETHREAD_SLEEP |
the number of milliseconds between each savethread execution
|
static long |
TIME_UTILTHREAD_SLEEP |
the number of milliseconds between each utilithread execution
|
Modifier and Type | Method | Description |
---|---|---|
void |
acceptConnection(java.net.Socket sock) |
Handles a connection from a user, and internal states
|
java.lang.String |
executeCommand(java.lang.String cmd) |
Flexible interface for tinkering with mud-host settings.
|
java.lang.String |
getHost() |
the hostname of the mud server
|
java.lang.String |
getLanguage() |
Return the viewable name of the language supported by this host.
|
java.util.List<java.lang.Runnable> |
getOverdueThreads() |
Return any internal threads that are a source of troubles
|
int |
getPort() |
the port a given MUD server instance is listening on
|
java.lang.String |
getStatus() |
Retrieve a string telling the status of mud startup or shutdown
|
long |
getUptimeSecs() |
Retrieve the number of seconds since startup
|
java.lang.String |
geWebHostUrl() |
The hostname, port of the most public web server for this host
Includes trailing slash
|
boolean |
isAcceptingConnections() |
Sets whether this mud is accepting connections
|
void |
setAcceptConnections(boolean truefalse) |
Sets whether this mud is accepting connections
|
void |
shutdown(Session S,
boolean keepItDown,
java.lang.String externalCommand) |
An order to permanently shutdown the entire mud system
|
java.lang.ThreadGroup |
threadGroup() |
Because thread groups are used to track configurations,
here is a way to get it.
|
static final long TIME_SAVETHREAD_SLEEP
static final long TIME_UTILTHREAD_SLEEP
static final char MAIN_HOST
java.lang.String getHost()
int getPort()
java.lang.String geWebHostUrl()
void shutdown(Session S, boolean keepItDown, java.lang.String externalCommand)
S
- a player session to send status messages to. May be null.keepItDown
- true to shutdown, false to restartexternalCommand
- if keepItDown is false, an external command to executejava.lang.String getStatus()
long getUptimeSecs()
java.util.List<java.lang.Runnable> getOverdueThreads()
java.lang.String getLanguage()
java.lang.String executeCommand(java.lang.String cmd) throws java.lang.Exception
cmd
- space-delimited (parsable) command/parm listjava.lang.Exception
- any exceptionsjava.lang.ThreadGroup threadGroup()
void setAcceptConnections(boolean truefalse)
truefalse
- whether it is accepting connectionsisAcceptingConnections()
void acceptConnection(java.net.Socket sock) throws java.net.SocketException, java.io.IOException
sock
- the socket the connection was made onjava.net.SocketException
- socket exceptionsjava.io.IOException
- io exceptionsboolean isAcceptingConnections()
setAcceptConnections(boolean)