Package net.glowstone
Class ConsoleManager
java.lang.Object
net.glowstone.ConsoleManager
A meta-class to handle all logging and input-related console improvements. Portions are heavily
based on CraftBukkit.
-
Constructor Summary
ConstructorDescriptionConsoleManager
(GlowServer server) Creates the instance for the given server. -
Method Summary
Modifier and TypeMethodDescriptionorg.bukkit.command.ConsoleCommandSender
Returns this ConsoleManager's console as a ConsoleCommandSender.void
startConsole
(boolean jline) Starts the console.void
Adds a console-log handler writing to the given file.void
stop()
Stops all console-log handlers.
-
Constructor Details
-
ConsoleManager
Creates the instance for the given server.- Parameters:
server
- the server
-
-
Method Details
-
startConsole
public void startConsole(boolean jline) Starts the console.- Parameters:
jline
- whether the console should use JLine
-
startFile
Adds a console-log handler writing to the given file.- Parameters:
logfile
- the file path
-
stop
public void stop()Stops all console-log handlers. -
getSender
public org.bukkit.command.ConsoleCommandSender getSender()Returns this ConsoleManager's console as a ConsoleCommandSender.- Returns:
- the ConsoleCommandSender instance for this ConsoleManager's console
-