add ability to remove root logging appender

This commit is contained in:
Craig Raw 2022-10-17 13:29:53 +02:00
parent f183146d13
commit 7c34ec7c3b

View file

@ -83,6 +83,11 @@ public class Drongo {
root.setLevel(ch.qos.logback.classic.Level.toLevel(level.toString()));
}
public static void removeRootLogAppender(String appenderName) {
ch.qos.logback.classic.Logger root = (ch.qos.logback.classic.Logger)LoggerFactory.getLogger(org.slf4j.Logger.ROOT_LOGGER_NAME);
root.detachAppender(appenderName);
}
public static Provider getProvider() {
return new BouncyCastleProvider();
}