1
2
3
4
5
6
7
8
9
10
11
12
13
14 package ch.qos.logback.core.util;
15
16 import ch.qos.logback.core.Context;
17 import ch.qos.logback.core.status.Status;
18 import ch.qos.logback.core.status.StatusManager;
19
20 import java.io.PrintStream;
21 import java.util.List;
22
23
24
25
26
27
28
29 public class StatusPrinter {
30
31 private final static StatusPrinter2 SINGLETON = new StatusPrinter2();
32
33 public static void setPrintStream(PrintStream printStream) {
34 SINGLETON.setPrintStream(printStream);
35 }
36
37
38
39
40
41
42
43 public static void printInCaseOfErrorsOrWarnings(Context context) {
44 SINGLETON.printInCaseOfErrorsOrWarnings(context, 0);
45 }
46
47
48
49
50
51
52
53
54 public static void printInCaseOfErrorsOrWarnings(Context context, long threshold) {
55 SINGLETON.printInCaseOfErrorsOrWarnings(context, threshold);
56 }
57
58
59
60
61
62
63 public static void printIfErrorsOccured(Context context) {
64 SINGLETON.printIfErrorsOccured(context);
65 }
66
67
68
69
70
71
72 public static void print(Context context) {
73 SINGLETON.print(context, 0);
74 }
75
76
77
78
79
80
81
82 public static void print(Context context, long threshold) {
83 SINGLETON.print(context, threshold);
84 }
85
86 public static void print(StatusManager sm) {
87 SINGLETON.print(sm, 0);
88 }
89
90 public static void print(StatusManager sm, long threshold) {
91 SINGLETON.print(sm, threshold);
92 }
93
94 public static void print(List<Status> statusList) {
95 SINGLETON.print(statusList);
96 }
97
98 public static void buildStr(StringBuilder sb, String indentation, Status s) {
99 SINGLETON.buildStr(sb, indentation, s);
100 }
101 }