diff options
author | Keuin <[email protected]> | 2020-04-23 23:27:33 +0800 |
---|---|---|
committer | keuin <[email protected]> | 2020-04-23 23:27:33 +0800 |
commit | c0b2237a12fc878ede8a8bbd48c9b4afa8290016 (patch) | |
tree | 2dfdea3defb57b7974e4b8c4d6e14bd376fcaafd /src/main/java/com/keuin/kbackupfabric/util/PrintUtil.java | |
parent | 36451c24439b6fc0a407b3aae12048125539f8d5 (diff) |
Split Log4j
Diffstat (limited to 'src/main/java/com/keuin/kbackupfabric/util/PrintUtil.java')
-rw-r--r-- | src/main/java/com/keuin/kbackupfabric/util/PrintUtil.java | 39 |
1 files changed, 0 insertions, 39 deletions
diff --git a/src/main/java/com/keuin/kbackupfabric/util/PrintUtil.java b/src/main/java/com/keuin/kbackupfabric/util/PrintUtil.java index de63037..fe98cfa 100644 --- a/src/main/java/com/keuin/kbackupfabric/util/PrintUtil.java +++ b/src/main/java/com/keuin/kbackupfabric/util/PrintUtil.java @@ -6,24 +6,12 @@ import net.minecraft.text.LiteralText; import net.minecraft.text.Style; import net.minecraft.text.Text; import net.minecraft.util.Formatting; -import org.apache.logging.log4j.LogManager; -import org.apache.logging.log4j.Logger; public final class PrintUtil { - private static final Logger LOGGER = LogManager.getLogger(); - - private static final boolean printDebugMessages = true; - private static final boolean printErrorMessages = true; - private static final boolean printInfoMessages = true; - - private static final Object syncDebug = new Object(); - private static final Object syncError = new Object(); - private static final Object syncInfo = new Object(); private static final Object syncMessage = new Object(); private static final Style infoStyle = new Style().setColor(Formatting.WHITE); - private static final Style debugStyle = new Style().setUnderline(true); private static final Style warnStyle = new Style().setColor(Formatting.YELLOW); private static final Style errorStyle = new Style().setColor(Formatting.DARK_RED); @@ -60,31 +48,4 @@ public final class PrintUtil { } return context; } - - public static void debug(String message) { - synchronized (syncDebug) { - if (printDebugMessages) { - //System.out.println(String.format("[DBG] [KB] %s", message)); - LOGGER.debug("[KB][DEBUG] " + message); - } - } - } - - public static void error(String message) { - synchronized (syncError) { - if (printErrorMessages) { - //System.out.println(String.format("[ERR] [KB] %s", message)); - LOGGER.error("[KB][ERROR]" + message); - } - } - } - - public static void info(String message) { - synchronized (syncInfo) { - if (printInfoMessages) { - //System.out.println(String.format("[INF] [KB] %s", message)); - LOGGER.info("[KB][INFO] " + message); - } - } - } } |