Interface SubServer
- All Superinterfaces:
ClientHandler
,ExtraDataHandler<String>
,Server
,ServerInfo
,SubDataSerializable
- All Known Implementing Classes:
ExternalSubServer
,InternalSubServer
,SubServerImpl
SubServer Interface
-
Nested Class Summary
Modifier and TypeInterfaceDescriptionstatic class
Command Storage Classstatic enum
SubServer Stop Action Class -
Method Summary
Modifier and TypeMethodDescriptiondefault int
Edits the Serverdefault int
Edits the ServerGets all the commands that were sent to this Server successfullyGet incompatibility issues this server currently hasGet the Server's Executable Stringdefault String
Get the Full Server Directory PathgetHost()
Grabs the Host of the ServerGet all listed incompatibilities for this ServerGet Process LoggergetPath()
Get the Server Directory PathGet the action the Server will take when it stopsGrab the Command to Stop the ServerGrabs the Template this Server was created fromboolean
Is this Host Available?boolean
isCompatible
(SubServer server) Checks if a Server is compatibledefault boolean
If the Server is accepting requests to edit()boolean
If the Server is Enabledboolean
If the Server is Loggingboolean
isOnline()
If the Server is Online
This method can only be true when a SubData connection is made!boolean
If the Server is Runningboolean
If the Server is Stopping
This method can only be true when the server is stopped through the server manager!default int
Edits the Server (& Saves Changes)default int
Edits the Server (& Saves Changes)void
setEnabled
(boolean value) Set if the Server is Enabledvoid
setLogging
(boolean value) Set if the Server is Loggingvoid
setStopAction
(SubServer.StopAction action) Set the action the Server will take when it stopsvoid
setStopCommand
(String value) Set the Command that Stops the Servervoid
setTemplate
(String value) Sets the Template this Server was created fromvoid
Sets the Template this Server was created fromdefault boolean
start()
Starts the Serverboolean
Starts the Serverdefault boolean
stop()
Stops the Serverboolean
Stops the Serverdefault boolean
Terminates the Serverboolean
Terminates the Servervoid
toggleCompatibility
(SubServer... server) Toggles compatibility with other Serversvoid
waitFor()
Waits for the Server to StopMethods inherited from interface net.ME1312.SubData.Server.ClientHandler
forSubData, getSubData, removeSubData
Methods inherited from interface net.ME1312.Galaxi.Library.ExtraDataHandler
addExtra, getExtra, getExtra, hasExtra, removeExtra
Methods inherited from interface net.ME1312.SubServers.Bungee.Host.Server
addGroup, command, command, command, getDisplayName, getGroups, getMotd, getRemotePlayers, getSignature, getWhitelist, isHidden, isRestricted, isWhitelisted, persist, removeGroup, setDisplayName, setHidden, setMotd, setRestricted, setSubData, unwhitelist, whitelist
Methods inherited from interface net.md_5.bungee.api.config.ServerInfo
canAccess, getAddress, getName, getPermission, getPlayers, getSocketAddress, ping, sendData, sendData
-
Method Details
-
start
Starts the Server- Parameters:
player
- Player who Started- Returns:
- Success Status
-
start
default boolean start()Starts the Server- Returns:
- Success Status
-
stop
Stops the Server- Parameters:
player
- Player who Stopped- Returns:
- Success Status
-
stop
default boolean stop()Stops the Server- Returns:
- Success Status
-
terminate
Terminates the Server- Parameters:
player
- Player who Terminated- Returns:
- Success Status
-
terminate
default boolean terminate()Terminates the Server- Returns:
- Success Status
-
edit
Edits the Server- Parameters:
player
- Player Editingedit
- Edits- Returns:
- Success Status
-
edit
Edits the Server- Parameters:
edit
- Edits- Returns:
- Success Status
-
permaEdit
Edits the Server (& Saves Changes)- Parameters:
player
- Player Editingedit
- Edits- Returns:
- Success Status
-
permaEdit
Edits the Server (& Saves Changes)- Parameters:
edit
- Edits- Returns:
- Success Status
-
waitFor
Waits for the Server to Stop- Throws:
InterruptedException
-
isRunning
boolean isRunning()If the Server is Running- Returns:
- Running Status
-
isOnline
boolean isOnline()If the Server is Online
This method can only be true when a SubData connection is made!- Returns:
- Online Status
-
isStopping
boolean isStopping()If the Server is Stopping
This method can only be true when the server is stopped through the server manager!- Returns:
- Stopping Status
-
getHost
Host getHost()Grabs the Host of the Server- Returns:
- The Host
-
getTemplate
SubCreator.ServerTemplate getTemplate()Grabs the Template this Server was created from- Returns:
- The Template
-
setTemplate
Sets the Template this Server was created from- Parameters:
value
- Value
-
setTemplate
Sets the Template this Server was created from- Parameters:
value
- Value
-
isAvailable
boolean isAvailable()Is this Host Available?- Returns:
- Availability Status
-
isEnabled
boolean isEnabled()If the Server is Enabled- Returns:
- Enabled Status
-
setEnabled
void setEnabled(boolean value) Set if the Server is Enabled- Parameters:
value
- Value
-
isEditable
default boolean isEditable()If the Server is accepting requests to edit()- Returns:
- Edit Status
- See Also:
-
isLogging
boolean isLogging()If the Server is Logging- Returns:
- Logging Status
-
setLogging
void setLogging(boolean value) Set if the Server is Logging- Parameters:
value
- Value
-
getLogger
SubLogger getLogger()Get Process Logger -
getCommandHistory
LinkedList<SubServer.LoggedCommand> getCommandHistory()Gets all the commands that were sent to this Server successfully- Returns:
- Command History
-
getPath
String getPath()Get the Server Directory Path- Returns:
- Server Directory Path
-
getFullPath
Get the Full Server Directory Path- Returns:
- Full Server Directory Path
-
getExecutable
String getExecutable()Get the Server's Executable String- Returns:
- Executable String
-
getStopCommand
String getStopCommand()Grab the Command to Stop the Server- Returns:
- Stop Command
-
setStopCommand
Set the Command that Stops the Server- Parameters:
value
- Value
-
getStopAction
SubServer.StopAction getStopAction()Get the action the Server will take when it stops- Returns:
- Stop Action
-
setStopAction
Set the action the Server will take when it stops- Parameters:
action
- Stop Action
-
toggleCompatibility
Toggles compatibility with other Servers- Parameters:
server
- SubServers to toggle
-
isCompatible
Checks if a Server is compatible- Parameters:
server
- Server to check- Returns:
- Compatible Status
-
getIncompatibilities
Get all listed incompatibilities for this Server- Returns:
- Incompatibility List
-
getCurrentIncompatibilities
Get incompatibility issues this server currently has- Returns:
- Current Incompatibility List
-