public class InternalSubServer extends SubServer
Constructor and Description |
---|
InternalSubServer(Host host,
java.lang.String name,
boolean enabled,
int port,
java.lang.String motd,
boolean log,
java.lang.String directory,
Executable executable,
java.lang.String stopcmd,
boolean start,
boolean restart,
boolean hidden,
boolean restricted,
boolean temporary) |
Modifier and Type | Method and Description |
---|---|
boolean |
command(java.util.UUID player,
java.lang.String command)
Commands the Server
|
java.lang.String |
getDirectory()
Get the Server Directory
|
Host |
getHost()
Grabs the Host of the Server
|
java.lang.String |
getStopCommand()
Grab the Command to Stop the Server
|
boolean |
isEnabled()
If the Server is Enabled
|
boolean |
isLogging()
If the Server is Logging
|
boolean |
isRunning()
If the Server is Running
|
boolean |
isTemporary()
If the Server is Temporary
|
void |
setAutoRestart(boolean value)
Set if the Server will Auto Restart on unexpected shutdowns
|
void |
setEnabled(boolean value)
Set if the Server is Enabled
|
void |
setLogging(boolean value)
Set if the Server is Logging
|
void |
setStopCommand(java.lang.String value)
Set the Command that Stops the Server
|
boolean |
start(java.util.UUID player)
Starts the Server
|
boolean |
stop(java.util.UUID player)
Stops the Server
|
boolean |
terminate(java.util.UUID player)
Terminates the Server
|
void |
waitFor()
Waits for the Server to Stop
|
boolean |
willAutoRestart()
If the Server will Auto Restart on unexpected shutdowns
|
command, start, stop, terminate
getMotd, getSubDataClient, isHidden, isRestricted, linkSubDataClient, setHidden, setMotd, setRestricted
public InternalSubServer(Host host, java.lang.String name, boolean enabled, int port, java.lang.String motd, boolean log, java.lang.String directory, Executable executable, java.lang.String stopcmd, boolean start, boolean restart, boolean hidden, boolean restricted, boolean temporary) throws InvalidServerException
InvalidServerException
public boolean start(java.util.UUID player)
SubServer
public boolean stop(java.util.UUID player)
SubServer
public boolean terminate(java.util.UUID player)
SubServer
public boolean command(java.util.UUID player, java.lang.String command)
SubServer
public void waitFor() throws java.lang.InterruptedException
SubServer
public boolean isRunning()
SubServer
public boolean isEnabled()
SubServer
public void setEnabled(boolean value)
SubServer
setEnabled
in class SubServer
value
- Valuepublic boolean isLogging()
SubServer
public void setLogging(boolean value)
SubServer
setLogging
in class SubServer
value
- Valuepublic java.lang.String getDirectory()
SubServer
getDirectory
in class SubServer
public java.lang.String getStopCommand()
SubServer
getStopCommand
in class SubServer
public void setStopCommand(java.lang.String value)
SubServer
setStopCommand
in class SubServer
value
- Valuepublic boolean willAutoRestart()
SubServer
willAutoRestart
in class SubServer
public void setAutoRestart(boolean value)
SubServer
setAutoRestart
in class SubServer
value
- Valuepublic boolean isTemporary()
SubServer
isTemporary
in class SubServer