1 package de.japrost.qa.checkstyle.blocks;
2
3
4
5
6 public class EmptyBlock {
7 private boolean bool = true;
8
9
10
11
12 static {
13 }
14
15
16
17
18 static {
19
20 }
21
22
23
24
25 static {
26 ;
27 }
28
29
30
31
32 {
33 }
34
35
36
37
38 {
39
40 }
41
42
43
44
45
46 {
47 ;
48 }
49
50 public void blocksEmpty() {
51
52 try {
53 } catch (Exception e) {
54 } finally {
55 }
56
57 while (bool) {
58 }
59
60 do {
61 } while (bool);
62
63 if (bool) {
64 } else {
65 }
66
67 for (int i = 0; i < 1; i++) {
68 }
69
70 switch (1) {
71 }
72
73 switch (1) {
74 case 1:
75 }
76
77 switch (1) {
78 default:
79 }
80
81 synchronized (this) {
82 }
83
84 @SuppressWarnings("unused")
85 int[] arrayInit = {};
86 }
87
88 public void blocksWithText() {
89
90 try {
91
92 } catch (Exception e) {
93
94 } finally {
95
96 }
97
98 while (bool) {
99
100 }
101
102 do {
103
104 } while (bool);
105
106 if (bool) {
107
108 } else {
109
110 }
111
112 for (int i = 0; i < 1; i++) {
113
114 }
115
116 switch (1) {
117
118 }
119
120 switch (1) {
121 case 1:
122
123 }
124
125 switch (1) {
126 default:
127
128 }
129
130 synchronized (this) {
131
132 }
133
134 @SuppressWarnings("unused")
135 int[] arrayInit = {
136 };
137 }
138
139 public void blocksWithStmt() {
140
141 try {
142 ;
143 } catch (Exception e) {
144 ;
145 } finally {
146 ;
147 }
148
149 while (bool) {
150 ;
151 }
152
153 do {
154 ;
155 } while (bool);
156
157 if (bool) {
158 ;
159 } else {
160 ;
161 }
162
163 for (int i = 0; i < 1; i++) {
164 ;
165 }
166
167
168
169
170
171 switch (1) {
172 case 1:
173 ;
174 }
175
176 switch (1) {
177 default:
178 ;
179 }
180
181 synchronized (this) {
182 ;
183 }
184
185 @SuppressWarnings("unused")
186 int[] arrayInit = { 1 };
187 }
188
189 }