Additional comments to logger

This commit is contained in:
Eric Stokes 2011-06-19 09:55:21 -06:00
parent 6af3964699
commit 665dccbcc5
2 changed files with 11 additions and 3 deletions

View File

@ -120,7 +120,7 @@ public class MultiverseCore extends JavaPlugin {
// Create our DataFolder
getDataFolder().mkdirs();
// Setup our Debug Log
debugLog = new DebugLog("Multiverse", getDataFolder() + File.separator + "debug.log");
debugLog = new DebugLog("Multiverse-Core", getDataFolder() + File.separator + "debug.log");
// Setup & Load our Configuration files.
loadConfigs();

View File

@ -15,7 +15,11 @@ public class DebugLog {
private FileHandler fh;
private Logger log;
/**
* Creates a new debug logger.
* @param logger The name of the logger.
* @param file The file to log to.
*/
public DebugLog(String logger, String file) {
log = Logger.getLogger(logger);
@ -34,7 +38,11 @@ public class DebugLog {
e.printStackTrace();
}
}
/**
* Log a message at a certain level
* @param level
* @param msg
*/
public void log(Level level, String msg) {
log.log(level, msg);
}