public interface ServerObject extends IdentifiableObject
Modifier and Type | Method and Description |
---|---|
APIRequestFuture<java.lang.Void> |
executeCommand(java.lang.String command)
Executes the given command as ConsoleSender on the server
|
BaseObject |
getBase()
Returns the base the server has been started by
|
java.lang.String |
getExtra()
An extra is a custom value users can set per API.
|
ServerGroupObject |
getGroup() |
java.lang.String |
getId() |
java.net.InetAddress |
getIpAddress() |
APIRequestFuture<LogFractionObject> |
getLogFraction(long startTime) |
APIRequestFuture<LogFractionObject> |
getLogFraction(long startTime,
long endTime) |
java.lang.String |
getMap()
If a server's map is assigned randomly, the map name will be the part of the map directory's name after the '_'.
|
int |
getMaxPlayerCount()
The server's maximum player count
|
MessageClientAddress |
getMessageAddress() |
java.lang.String |
getMotd()
The server's MOTD (= message of the day)
|
java.lang.String |
getName() |
int |
getOnlinePlayerCount()
The server's current online player count
|
java.util.Collection<PlayerObject> |
getOnlinePlayers() |
int |
getPort() |
java.net.InetSocketAddress |
getSocketAddress() |
java.lang.String |
getState() |
boolean |
isSortedOut() |
void |
sendPluginMessage(PluginMessage message)
Send a plugin message to the server
|
APIRequestFuture<java.lang.Void> |
setExtra(java.lang.String extra)
An extra is a custom value users can set per API.
|
APIRequestFuture<java.lang.Void> |
setState(java.lang.String state)
Sets the server's state and sends it to TimoCloud BungeeCord
|
APIRequestFuture<java.lang.Void> |
stop()
Stops the server
|
java.lang.String getName()
getName
in interface IdentifiableObject
java.lang.String getId()
getId
in interface IdentifiableObject
ServerGroupObject getGroup()
java.lang.String getState()
APIRequestFuture<java.lang.Void> setState(java.lang.String state)
state
- The state, e.g. 'INGAME' or 'FULL'java.lang.String getExtra()
APIRequestFuture<java.lang.Void> setExtra(java.lang.String extra)
java.lang.String getMap()
java.lang.String getMotd()
java.util.Collection<PlayerObject> getOnlinePlayers()
int getOnlinePlayerCount()
int getMaxPlayerCount()
BaseObject getBase()
java.net.InetSocketAddress getSocketAddress()
java.net.InetAddress getIpAddress()
int getPort()
boolean isSortedOut()
MessageClientAddress getMessageAddress()
APIRequestFuture<java.lang.Void> executeCommand(java.lang.String command)
command
- Without leading /APIRequestFuture<java.lang.Void> stop()
void sendPluginMessage(PluginMessage message)
message
- The message which shall be sentAPIRequestFuture<LogFractionObject> getLogFraction(long startTime, long endTime)
startTime
- The timestamp at which the record of the log should start (0 if you want all log entries since the server's start)endTime
- The timestamp at which the record of the log should endAPIRequestFuture<LogFractionObject> getLogFraction(long startTime)
startTime
- The timestamp at which the record of the log should start (0 if you want all log entries since the server's start)