ExcessivePublicCountSuppressionWorksForPublicStaticMethods   F
last analyzed

Complexity

Total Complexity 71

Size/Duplication

Total Lines 286
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Importance

Changes 0
Metric Value
dl 0
loc 286
rs 2.7199
c 0
b 0
f 0
wmc 71
lcom 0
cbo 0

71 Methods

Rating   Name   Duplication   Size   Complexity  
A aMethod() 0 3 1
A bMethod() 0 3 1
A cMethod() 0 3 1
A dMethod() 0 3 1
A eMethod() 0 3 1
A fMethod() 0 3 1
A gMethod() 0 3 1
A hMethod() 0 3 1
A iMethod() 0 3 1
A jMethod() 0 3 1
A kMethod() 0 3 1
A lMethod() 0 3 1
A mMethod() 0 3 1
A nMethod() 0 3 1
A oMethod() 0 3 1
A pMethod() 0 3 1
A rMethod() 0 3 1
A sMethod() 0 3 1
A tMethod() 0 3 1
A uMethod() 0 3 1
A wMethod() 0 3 1
A xMethod() 0 3 1
A yMethod() 0 3 1
A zMethod() 0 3 1
A aaMethod() 0 3 1
A abMethod() 0 3 1
A acMethod() 0 3 1
A adMethod() 0 3 1
A aeMethod() 0 3 1
A afMethod() 0 3 1
A agMethod() 0 3 1
A ahMethod() 0 3 1
A ajMethod() 0 3 1
A akMethod() 0 3 1
A alMethod() 0 3 1
A amMethod() 0 3 1
A anMethod() 0 3 1
A aoMethod() 0 3 1
A apMethod() 0 3 1
A arMethod() 0 3 1
A asMethod() 0 3 1
A atMethod() 0 3 1
A auMethod() 0 3 1
A awMethod() 0 3 1
A axMethod() 0 3 1
A ayMethod() 0 3 1
A azMethod() 0 3 1
A baMethod() 0 3 1
A bbMethod() 0 3 1
A bcMethod() 0 3 1
A bdMethod() 0 3 1
A beMethod() 0 3 1
A bfMethod() 0 3 1
A bgMethod() 0 3 1
A bhMethod() 0 3 1
A biMethod() 0 3 1
A bjMethod() 0 3 1
A bkMethod() 0 3 1
A blmethod() 0 3 1
A bmmethod() 0 3 1
A bnMethod() 0 3 1
A boMethod() 0 3 1
A bpMethod() 0 3 1
A brMethod() 0 3 1
A bsMethod() 0 3 1
A btMethod() 0 3 1
A buMethod() 0 3 1
A bwMethod() 0 3 1
A bxMethod() 0 3 1
A byMethod() 0 3 1
A bzMethod() 0 3 1

How to fix   Complexity   

Complex Class

Complex classes like ExcessivePublicCountSuppressionWorksForPublicStaticMethods often do a lot of different things. To break such a class down, we need to identify a cohesive component within that class. A common approach to find such a component is to look for fields/methods that share the same prefixes, or suffixes. You can also have a look at the cohesion graph to spot any un-connected, or weakly-connected components.

Once you have determined the fields that belong together, you can apply the Extract Class refactoring. If the component makes sense as a sub-class, Extract Subclass is also a candidate, and is often faster.

While breaking up the class, it is a good idea to analyze how other classes use ExcessivePublicCountSuppressionWorksForPublicStaticMethods, and based on these observations, apply Extract Interface, too.

1
<?php
2
/**
3
 * This file is part of PHP Mess Detector.
4
 *
5
 * Copyright (c) Manuel Pichler <[email protected]>.
6
 * All rights reserved.
7
 *
8
 * Licensed under BSD License
9
 * For full copyright and license information, please see the LICENSE file.
10
 * Redistributions of files must retain the above copyright notice.
11
 *
12
 * @author Manuel Pichler <[email protected]>
13
 * @copyright Manuel Pichler. All rights reserved.
14
 * @license https://opensource.org/licenses/bsd-license.php BSD License
15
 * @link http://phpmd.org/
16
 */
17
18
namespace PHPMD\Regression\Sources;
19
20
/**
21
 * @SuppressWarnings(PHPMD.ExcessivePublicCount)
22
 */
23
class ExcessivePublicCountSuppressionWorksForPublicStaticMethods
24
{
25
    public static function aMethod()
26
    {
27
    }
28
29
    public static function bMethod()
30
    {
31
    }
32
33
    public static function cMethod()
34
    {
35
    }
36
37
    public static function dMethod()
38
    {
39
    }
40
41
    public static function eMethod()
42
    {
43
    }
44
45
    public static function fMethod()
46
    {
47
    }
48
49
    public static function gMethod()
50
    {
51
    }
52
53
    public static function hMethod()
54
    {
55
    }
56
57
    public static function iMethod()
58
    {
59
    }
60
61
    public static function jMethod()
62
    {
63
    }
64
65
    public static function kMethod()
66
    {
67
    }
68
69
    public static function lMethod()
70
    {
71
    }
72
73
    public static function mMethod()
74
    {
75
    }
76
77
    public static function nMethod()
78
    {
79
    }
80
81
    public static function oMethod()
82
    {
83
    }
84
85
    public static function pMethod()
86
    {
87
    }
88
89
    public static function rMethod()
90
    {
91
    }
92
93
    public static function sMethod()
94
    {
95
    }
96
97
    public static function tMethod()
98
    {
99
    }
100
101
    public static function uMethod()
102
    {
103
    }
104
105
    public static function wMethod()
106
    {
107
    }
108
109
    public static function xMethod()
110
    {
111
    }
112
113
    public static function yMethod()
114
    {
115
    }
116
117
    public static function zMethod()
118
    {
119
    }
120
121
    public static function aaMethod()
122
    {
123
    }
124
125
    public static function abMethod()
126
    {
127
    }
128
129
    public static function acMethod()
130
    {
131
    }
132
133
    public static function adMethod()
134
    {
135
    }
136
137
    public static function aeMethod()
138
    {
139
    }
140
141
    public static function afMethod()
142
    {
143
    }
144
145
    public static function agMethod()
146
    {
147
    }
148
149
    public static function ahMethod()
150
    {
151
    }
152
153
    public static function ajMethod()
154
    {
155
    }
156
157
    public static function akMethod()
158
    {
159
    }
160
161
    public static function alMethod()
162
    {
163
    }
164
165
    public static function amMethod()
166
    {
167
    }
168
169
    public static function anMethod()
170
    {
171
    }
172
173
    public static function aoMethod()
174
    {
175
    }
176
177
    public static function apMethod()
178
    {
179
    }
180
181
    public static function arMethod()
182
    {
183
    }
184
185
    public static function asMethod()
186
    {
187
    }
188
189
    public static function atMethod()
190
    {
191
    }
192
193
    public static function auMethod()
194
    {
195
    }
196
197
    public static function awMethod()
198
    {
199
    }
200
201
    public static function axMethod()
202
    {
203
    }
204
205
    public static function ayMethod()
206
    {
207
    }
208
209
    public static function azMethod()
210
    {
211
    }
212
213
    public static function baMethod()
214
    {
215
    }
216
217
    public static function bbMethod()
218
    {
219
    }
220
221
    public static function bcMethod()
222
    {
223
    }
224
225
    public static function bdMethod()
226
    {
227
    }
228
229
    public static function beMethod()
230
    {
231
    }
232
233
    public static function bfMethod()
234
    {
235
    }
236
237
    public static function bgMethod()
238
    {
239
    }
240
241
    public static function bhMethod()
242
    {
243
    }
244
245
    public static function biMethod()
246
    {
247
    }
248
249
    public static function bjMethod()
250
    {
251
    }
252
253
    public static function bkMethod()
254
    {
255
    }
256
257
    public static function blmethod()
258
    {
259
    }
260
261
    public static function bmmethod()
262
    {
263
    }
264
265
    public static function bnMethod()
266
    {
267
    }
268
269
    public static function boMethod()
270
    {
271
    }
272
273
    public static function bpMethod()
274
    {
275
    }
276
277
    public static function brMethod()
278
    {
279
    }
280
281
    public static function bsMethod()
282
    {
283
    }
284
285
    public static function btMethod()
286
    {
287
    }
288
289
    public static function buMethod()
290
    {
291
    }
292
293
    public static function bwMethod()
294
    {
295
    }
296
297
    public static function bxMethod()
298
    {
299
    }
300
301
    public static function byMethod()
302
    {
303
    }
304
305
    public static function bzMethod()
306
    {
307
    }
308
}
309