1 package ch.qos.logback.core.filter;
2
3 import ch.qos.logback.core.spi.ContextAwareBase;
4 import ch.qos.logback.core.spi.FilterReply;
5 import ch.qos.logback.core.spi.LifeCycle;
6
7
8
9
10
11
12
13
14
15
16
17
18 public abstract class Filter<E> extends ContextAwareBase implements LifeCycle {
19
20 private String name;
21
22 boolean start = false;
23
24 public void start() {
25 this.start = true;
26 }
27
28 public boolean isStarted() {
29 return this.start;
30 }
31
32 public void stop() {
33 this.start = false;
34 }
35
36
37
38
39
40
41
42
43
44
45
46 public abstract FilterReply decide(E event);
47
48 public String getName() {
49 return name;
50 }
51
52 public void setName(String name) {
53 this.name = name;
54 }
55 }