org.apache.juli.logging.ch.qos.logback.core.model.processor.DenyModelFilter Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of tomcat85-slf4j-logback Show documentation
Show all versions of tomcat85-slf4j-logback Show documentation
Tomcat85 Slf4j Logback Integration
package org.apache.juli.logging.ch.qos.logback.core.model.processor;
import org.apache.juli.logging.ch.qos.logback.core.model.Model;
import org.apache.juli.logging.ch.qos.logback.core.spi.FilterReply;
public class DenyModelFilter implements ModelFilter {
final Class deniedModelType;
DenyModelFilter(Class deniedModelType) {
this.deniedModelType = deniedModelType;
}
@Override
public FilterReply decide(Model model) {
if (model.getClass() == deniedModelType) {
return FilterReply.DENY;
}
return FilterReply.NEUTRAL;
}
}