Class DIH4JDALogger

java.lang.Object
xyz.dynxsty.dih4jda.DIH4JDALogger

public class DIH4JDALogger extends Object
This handler's own Logging System.
To disable certain DIH4JDALogger.Types, simple use disableLogging(Type...).
  • Constructor Details

    • DIH4JDALogger

      public DIH4JDALogger()
      Creates a new, default instance of the DIH4JDALogger.
  • Method Details

    • disableLogging

      public static void disableLogging(@Nonnull DIH4JDALogger.Type... types)
      Sets the types of logging that should be disabled.
      Parameters:
      types - All DIH4JDALogger.Type's that should be disabled.
    • info

      public static void info(@Nonnull DIH4JDALogger.Type type, @Nonnull String msg, @Nonnull Object... args)
      Logs a message with the specified DIH4JDALogger.Type and Level.INFO.
      Parameters:
      type - The DIH4JDALogger.Type of the message.
      msg - The message to log.
      args - The arguments to format the message with.
    • info

      public static void info(@Nonnull String msg, @Nonnull Object... args)
      Logs a message with the specified Level.INFO.
      Parameters:
      msg - The message to log.
      args - The arguments to format the message with.
    • warn

      public static void warn(@Nonnull DIH4JDALogger.Type type, @Nonnull String msg, @Nonnull Object... args)
      Logs a message with the specified DIH4JDALogger.Type and Level.WARN.
      Parameters:
      type - The DIH4JDALogger.Type of the message.
      msg - The message to log.
      args - The arguments to format the message with.
    • warn

      public static void warn(@Nonnull String msg, @Nonnull Object... args)
      Logs a message with the specified Level.WARN.
      Parameters:
      msg - The message to log.
      args - The arguments to format the message with.
    • error

      public static void error(@Nonnull DIH4JDALogger.Type type, @Nonnull String msg, @Nonnull Object... args)
      Logs a message with the specified DIH4JDALogger.Type and Level.ERROR.
      Parameters:
      type - The DIH4JDALogger.Type of the message.
      msg - The message to log.
      args - The arguments to format the message with.
    • error

      public static void error(@Nonnull String msg, @Nonnull Object... args)
      Logs a message with the specified Level.ERROR.
      Parameters:
      msg - The message to log.
      args - The arguments to format the message with.
    • debug

      public static void debug(@Nonnull DIH4JDALogger.Type type, @Nonnull String msg, @Nonnull Object... args)
      Logs a message with the specified DIH4JDALogger.Type and Level.DEBUG.
      Parameters:
      type - The DIH4JDALogger.Type of the message.
      msg - The message to log.
      args - The arguments to format the message with.
    • debug

      public static void debug(@Nonnull String msg, @Nonnull Object... args)
      Logs a message with the specified Level.DEBUG.
      Parameters:
      msg - The message to log.
      args - The arguments to format the message with.
    • trace

      public static void trace(@Nonnull DIH4JDALogger.Type type, @Nonnull String msg, @Nonnull Object... args)
      Logs a message with the specified DIH4JDALogger.Type and Level.TRACE.
      Parameters:
      type - The DIH4JDALogger.Type of the message.
      msg - The message to log.
      args - The arguments to format the message with.
    • trace

      public static void trace(@Nonnull String msg, @Nonnull Object... args)
      Logs a message with the specified Level.TRACE.
      Parameters:
      msg - The message to log.
      args - The arguments to format the message with.