OSDN Git Service

cosmetic updates
[dictzip-java/dictzip-java.git] / doc / codingstyle_checks.xml
1 <?xml version="1.0"?>
2 <!DOCTYPE module PUBLIC
3           "-//Puppy Crawl//DTD Check Configuration 1.3//EN"
4           "http://www.puppycrawl.com/dtds/configuration_1_3.dtd">
5
6 <!--
7
8   Checkstyle configuration that checks the sun coding conventions from:
9
10     - the Java Language Specification at
11       http://java.sun.com/docs/books/jls/second_edition/html/index.html
12
13     - the Sun Code Conventions at http://java.sun.com/docs/codeconv/
14
15     - the Javadoc guidelines at
16       http://java.sun.com/j2se/javadoc/writingdoccomments/index.html
17
18     - the JDK Api documentation http://java.sun.com/j2se/docs/api/index.html
19
20     - some best practices
21
22   Checkstyle is very configurable. Be sure to read the documentation at
23   http://checkstyle.sf.net (or in your downloaded distribution).
24
25   Most Checks are configurable, be sure to consult the documentation.
26
27   To completely disable a check, just comment it out or delete it from the file.
28
29   Finally, it is worth reading the documentation.
30
31 -->
32
33 <module name="Checker">
34     <!--
35         If you set the basedir property below, then all reported file
36         names will be relative to the specified directory. See
37         http://checkstyle.sourceforge.net/5.x/config.html#Checker
38
39         <property name="basedir" value="${basedir}"/>
40     -->
41     <property name="charset" value="UTF-8"/>
42
43     <property name="severity" value="warning"/>
44
45     <property name="fileExtensions" value="java, properties, xml"/>
46
47     <!-- Checks whether files end with a new line.                        -->
48     <!-- See http://checkstyle.sf.net/config_misc.html#NewlineAtEndOfFile -->
49     <module name="NewlineAtEndOfFile"/>
50
51     <!-- Checks that property files contain the same keys.         -->
52     <!-- See http://checkstyle.sf.net/config_misc.html#Translation -->
53     <module name="Translation"/>
54
55     <!-- Checks for Size Violations.                    -->
56     <!-- See http://checkstyle.sf.net/config_sizes.html -->
57     <module name="FileLength"/>
58
59     <!-- Checks for whitespace                               -->
60     <!-- See http://checkstyle.sf.net/config_whitespace.html -->
61     <module name="FileTabCharacter"/>
62
63     <!-- Miscellaneous other checks.                   -->
64     <!-- See http://checkstyle.sf.net/config_misc.html -->
65     <module name="RegexpSingleline">
66        <property name="format" value="\s+$"/>
67        <property name="minimum" value="0"/>
68        <property name="maximum" value="0"/>
69        <property name="message" value="Line has trailing spaces."/>
70     </module>
71
72     <!-- Checks for Headers                                -->
73     <!-- See http://checkstyle.sf.net/config_header.html   -->
74     <!-- <module name="Header"> -->
75     <!--   <property name="headerFile" value="${checkstyle.header.file}"/> -->
76     <!--   <property name="fileExtensions" value="java"/> -->
77     <!-- </module> -->
78
79     <module name="TreeWalker">
80
81         <!-- Checks for Javadoc comments.                     -->
82         <!-- See http://checkstyle.sf.net/config_javadoc.html -->
83         <module name="JavadocMethod">
84             <property name="scope" value="public"/>
85         </module>
86         <module name="JavadocType"/>
87         <module name="JavadocVariable">
88             <property name="scope" value="public"/>
89         </module>
90         <module name="JavadocStyle"/>
91
92         <!-- Checks for Naming Conventions.                  -->
93         <!-- See http://checkstyle.sf.net/config_naming.html -->
94         <module name="ConstantName"/>
95         <module name="LocalFinalVariableName"/>
96         <module name="LocalVariableName"/>
97         <module name="MemberName"/>
98         <module name="MethodName"/>
99         <module name="PackageName"/>
100         <module name="ParameterName"/>
101         <module name="StaticVariableName"/>
102         <module name="TypeName"/>
103
104         <!-- Checks for imports                              -->
105         <!-- See http://checkstyle.sf.net/config_import.html -->
106         <module name="AvoidStarImport"/>
107         <module name="IllegalImport"/> <!-- defaults to sun.* packages -->
108         <module name="RedundantImport"/>
109         <module name="UnusedImports">
110             <property name="processJavadoc" value="false"/>
111         </module>
112
113         <!-- Checks for Size Violations.                    -->
114         <!-- See http://checkstyle.sf.net/config_sizes.html -->
115         <module name="LineLength">
116             <property name="max" value="100"/>
117         </module>
118
119         <module name="MethodLength"/>
120         <module name="ParameterNumber"/>
121
122         <!-- Checks for whitespace                               -->
123         <!-- See http://checkstyle.sf.net/config_whitespace.html -->
124         <module name="EmptyForIteratorPad"/>
125         <module name="GenericWhitespace"/>
126         <module name="MethodParamPad"/>
127         <module name="NoWhitespaceAfter"/>
128         <module name="NoWhitespaceBefore"/>
129         <module name="OperatorWrap"/>
130         <module name="ParenPad"/>
131         <module name="TypecastParenPad"/>
132         <module name="WhitespaceAfter"/>
133         <module name="WhitespaceAround"/>
134
135         <!-- Modifier Checks                                    -->
136         <!-- See http://checkstyle.sf.net/config_modifiers.html -->
137         <module name="ModifierOrder"/>
138         <module name="RedundantModifier"/>
139
140         <!-- Checks for blocks. You know, those {}'s         -->
141         <!-- See http://checkstyle.sf.net/config_blocks.html -->
142         <module name="AvoidNestedBlocks"/>
143         <module name="EmptyBlock"/>
144         <module name="LeftCurly"/>
145         <module name="NeedBraces"/>
146         <module name="RightCurly"/>
147
148         <!-- Checks for common coding problems               -->
149         <!-- See http://checkstyle.sf.net/config_coding.html -->
150         <module name="AvoidInlineConditionals"/>
151         <module name="EmptyStatement"/>
152         <module name="EqualsHashCode"/>
153         <module name="HiddenField"/>
154         <module name="IllegalInstantiation"/>
155         <module name="InnerAssignment"/>
156         <!-- <module name="MagicNumber"/> -->
157         <module name="MissingSwitchDefault"/>
158         <module name="SimplifyBooleanExpression"/>
159         <module name="SimplifyBooleanReturn"/>
160
161         <!-- Checks for class design                         -->
162         <!-- See http://checkstyle.sf.net/config_design.html -->
163         <!--
164         <module name="DesignForExtension"/>
165         -->
166         <module name="FinalClass"/>
167         <module name="HideUtilityClassConstructor"/>
168         <module name="InterfaceIsType"/>
169         <module name="VisibilityModifier"/>
170
171         <!-- Miscellaneous other checks.                   -->
172         <!-- See http://checkstyle.sf.net/config_misc.html -->
173         <module name="ArrayTypeStyle"/>
174         <module name="FinalParameters"/>
175         <module name="TodoComment"/>
176         <module name="UpperEll"/>
177
178     </module>
179
180 </module>