forked from DiscordBolt/BoltBot-2019
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Create our own slf4j logger instance
- Loading branch information
1 parent
19232b3
commit 5cc3832
Showing
1 changed file
with
10 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,30 +1,33 @@ | ||
package net.ajpappas.discord.utils; | ||
|
||
import sx.blah.discord.Discord4J; | ||
import net.ajpappas.discord.Discord; | ||
import org.slf4j.LoggerFactory; | ||
|
||
public class Logger { | ||
|
||
private static final org.slf4j.Logger LOGGER = LoggerFactory.getLogger(Discord.class); | ||
|
||
public static void trace(String s) { | ||
Discord4J.LOGGER.trace(s); | ||
LOGGER.trace(s); | ||
} | ||
|
||
public static void debug(Throwable e) { | ||
Discord4J.LOGGER.debug(e.getMessage(), e); | ||
LOGGER.debug(e.getMessage(), e); | ||
} | ||
|
||
public static void debug(String s) { | ||
Discord4J.LOGGER.debug(s); | ||
LOGGER.debug(s); | ||
} | ||
|
||
public static void info(String s) { | ||
Discord4J.LOGGER.info(s); | ||
LOGGER.info(s); | ||
} | ||
|
||
public static void warning(String s) { | ||
Discord4J.LOGGER.warn(s); | ||
LOGGER.warn(s); | ||
} | ||
|
||
public static void error(String s) { | ||
Discord4J.LOGGER.error(s); | ||
LOGGER.error(s); | ||
} | ||
} |