checkstyle.jeed.xml Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of core Show documentation
Show all versions of core Show documentation
Sandboxing and code analysis toolkit for CS 124.
<?xml version="1.0"?> <!DOCTYPE module PUBLIC "-//Puppy Crawl//DTD Check Configuration 1.3//EN" "http://checkstyle.sourceforge.net/dtds/configuration_1_3.dtd"> <!-- Checkstyle configuration that checks the sun coding conventions from: - the Java Language Specification at http://java.sun.com/docs/books/jls/second_edition/html/index.html - the Sun Code Conventions at http://java.sun.com/docs/codeconv/ - the Javadoc guidelines at http://java.sun.com/j2se/javadoc/writingdoccomments/index.html - the JDK Api documentation http://java.sun.com/j2se/docs/api/index.html - some best practices Checkstyle is very configurable. Be sure to read the documentation at http://checkstyle.sf.net (or in your downloaded distribution). Most Checks are configurable, be sure to consult the documentation. To completely disable a check, just comment it out or delete it from the file. Finally, it is worth reading the documentation. --> <!-- Configuration customized for CS124. Changes marked with "CS124". --> <module name="Checker"> <module name="SuppressWarningsFilter" /> <property name="fileExtensions" value="java"/> <!-- Checks that a package-info.java file exists for each package. --> <!-- See http://checkstyle.sf.net/config_javadoc.html#JavadocPackage --> <!-- CS124: we don't create a package. <module name="JavadocPackage"/> --> <!-- Checks whether files end with a new line. --> <!-- See http://checkstyle.sf.net/config_misc.html#NewlineAtEndOfFile --> <!-- CS124: we don't need to check this. <module name="NewlineAtEndOfFile"> <property name="lineSeparator" value="lf_cr_crlf"/> </module> --> <!-- Checks that property files contain the same keys. --> <!-- See http://checkstyle.sf.net/config_misc.html#Translation --> <!-- CS124: we don't check these files at all. <module name="Translation"/> --> <!-- Checks for Size Violations. --> <!-- See http://checkstyle.sf.net/config_sizes.html --> <module name="FileLength"/> <!-- Checks for whitespace --> <!-- See http://checkstyle.sf.net/config_whitespace.html --> <module name="FileTabCharacter"/> <!-- Miscellaneous other checks. --> <!-- See http://checkstyle.sf.net/config_misc.html --> <!-- CS124: we're going to be lenient about trailing space. <module name="RegexpSingleline"> <property name="format" value="\s+$"/> <property name="minimum" value="0"/> <property name="maximum" value="0"/> <property name="message" value="Line has trailing spaces."/> </module> --> <!-- Checks for Size Violations. --> <!-- See http://checkstyle.sf.net/config_sizes.html --> <!-- CS124: 80 characters is too few on modern monitors. Google's style guide uses 120, and so do we. --> <module name="LineLength"> <property name="max" value="120"/> </module> <module name="TreeWalker"> <module name="SuppressWarningsHolder" /> <!-- Checks for Javadoc comments. --> <!-- See http://checkstyle.sf.net/config_javadoc.html --> <!-- CS124: we don't require Javadoc comments by default. <module name="JavadocMethod"/> <module name="JavadocType"/> <module name="JavadocVariable"/> <module name="JavadocStyle"/> --> <!-- Checks for Naming Conventions. --> <!-- See http://checkstyle.sf.net/config_naming.html --> <module name="ConstantName"/> <module name="LocalFinalVariableName"/> <module name="LocalVariableName"/> <module name="MemberName"/> <module name="MethodName"/> <module name="PackageName"/> <module name="ParameterName"/> <module name="StaticVariableName"/> <module name="TypeName"/> <!-- Checks for imports --> <!-- See http://checkstyle.sf.net/config_import.html --> <module name="AvoidStarImport"/> <module name="IllegalImport"/> <!-- defaults to sun.* packages --> <module name="RedundantImport"/> <module name="UnusedImports"> <property name="processJavadoc" value="false"/> </module> <module name="MethodLength"/> <module name="ParameterNumber"/> <!-- Checks for whitespace --> <!-- See http://checkstyle.sf.net/config_whitespace.html --> <module name="EmptyForIteratorPad"> <property name="option" value="space" /> </module> <module name="GenericWhitespace"/> <module name="MethodParamPad"/> <module name="NoWhitespaceAfter"/> <module name="NoWhitespaceBefore"/> <module name="OperatorWrap"/> <module name="ParenPad"/> <module name="TypecastParenPad"/> <module name="WhitespaceAfter"/> <module name="WhitespaceAround"> <property name="allowEmptyTypes" value="true" /> <property name="allowEmptyMethods" value="true" /> <property name="allowEmptyConstructors" value="true" /> <property name="allowEmptyLambdas" value="true" /> </module> <!-- Modifier Checks --> <!-- See http://checkstyle.sf.net/config_modifiers.html --> <module name="ModifierOrder"/> <module name="RedundantModifier"/> <!-- Checks for blocks. You know, those {}'s --> <!-- See http://checkstyle.sf.net/config_blocks.html --> <module name="AvoidNestedBlocks"/> <module name="EmptyBlock"/> <module name="LeftCurly"/> <!-- CS124: allow empty for loops for list problems. --> <module name="NeedBraces"> <property name="allowEmptyLoopBody" value="true"/> </module> <module name="RightCurly"/> <!-- Checks for common coding problems --> <!-- See http://checkstyle.sf.net/config_coding.html --> <module name="AvoidInlineConditionals"/> <module name="EmptyStatement" /> <!-- CS124: don't enforce this <module name="EqualsHashCode"/> --> <module name="HiddenField"/> <module name="IllegalInstantiation"/> <module name="InnerAssignment"/> <!-- CS124: disabled by default. <module name="MagicNumber"/> --> <module name="MissingSwitchDefault"/> <!-- CS124: if (test == true) is clear. --> <!-- <module name="SimplifyBooleanExpression"/> --> <module name="SimplifyBooleanReturn" /> <!-- Checks for class design --> <!-- See http://checkstyle.sf.net/config_design.html --> <!-- CS124: No need for this warning. <module name="DesignForExtension"/> --> <module name="FinalClass"/> <!-- CS124: Our utility classes must have public main methods. <module name="HideUtilityClassConstructor"/> --> <module name="InterfaceIsType"/> <!-- CS124: allow public fields by default, although this might be worth disabling on a per-question basis. <module name="VisibilityModifier"/> --> <!-- Miscellaneous other checks. --> <!-- See http://checkstyle.sf.net/config_misc.html --> <module name="ArrayTypeStyle"/> <!-- CS124: Disabling by default, since throwing final everywhere is fairly annoying. <module name="FinalParameters"/> --> <module name="TodoComment"/> <module name="UpperEll"/> <module name="Indentation"> <property name="basicOffset" value="2"/> <property name="caseIndent" value="2"/> <property name="arrayInitIndent" value="2"/> <property name="lineWrappingIndentation" value="2"/> </module> <module name="OneStatementPerLine"/> <module name="EmptyStatement"/> <module name="ParameterAssignment"/> <module name="StringLiteralEquality"/> </module> </module>