This repository has been archived by the owner on May 2, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathcheckstyle.xml
56 lines (45 loc) · 2.21 KB
/
checkstyle.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
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
51
52
53
54
55
56
<?xml version="1.0"?>
<!DOCTYPE module PUBLIC "-//Puppy Crawl//DTD Check Configuration 1.2//EN"
"http://www.puppycrawl.com/dtds/configuration_1_2.dtd">
<module name="Checker">
<!-- Source code is not formatted using tabs -->
<module name="FileTabCharacter" />
<module name="SuppressWarningsFilter" />
<module name="TreeWalker">
<!-- Checks for imports -->
<module name="AvoidStarImport" />
<module name="RedundantImport" />
<module name="UnusedImports" />
<!-- Checks for common coding problems -->
<module name="IllegalInstantiation" />
<!-- Miscellaneous other checks. -->
<module name="GenericWhitespace" />
<module name="PackageAnnotation" />
<module name="EmptyStatement" />
<module name="DefaultComesLast" />
<!-- Nobody should be using StringBuffer anymore -->
<module name="RegexpSinglelineJava">
<property name="format" value=" StringBuffer" />
<!-- The last sentence of the message is a keyword to trigger exclusion: see ExcludeTestPackages -->
<property name="message" value="Nobody should be using StringBuffer anymore" />
</module>
<!-- Allow annotated code to disable checkstyle check -->
<module name="SuppressWarningsHolder" />
</module>
<!-- We are not using NewLineAtEndOfFile because the new line chars change
on different operating systems and that rule allows only one type. This rule
is not actually checking for new lines, but it will work if we check that
there are not white spaces at the end of a line with another rule. -->
<module name="RegexpMultiline">
<property name="format" value="\S\z" />
<property name="message" value="Missing new line at the end of file" />
</module>
<module name="RegexpMultiline">
<property name="format" value="((\r\n){2,}|(\n){2,}|(\r){2,})\z" />
<property name="message" value="Only one new line is allowed at the end of a file" />
</module>
<module name="RegexpSingleline">
<property name="format" value="\s+$" />
<property name="message" value="White spaces at the end of line" />
</module>
</module>