org.sonar.plugins.checkstyle.profile-sun-conventions.xml Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of sonar-checkstyle-plugin Show documentation
Show all versions of sonar-checkstyle-plugin Show documentation
Checkstyle is a code analyser to help programmers write Java code that adheres to a coding standard.
<profile> <name>Sun checks</name> <language>java</language> <rules> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.NewlineAtEndOfFileCheck</key> <parameters> <parameter> <key>lineSeparator</key> <value>system</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.whitespace.WhitespaceAfterCheck</key> <parameters> <parameter> <key>tokens</key> <value>COMMA,SEMI,TYPECAST</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.whitespace.FileTabCharacterCheck</key> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.coding.MissingSwitchDefaultCheck</key> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.whitespace.EmptyForIteratorPadCheck</key> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.coding.SimplifyBooleanExpressionCheck</key> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.modifier.ModifierOrderCheck</key> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.design.HideUtilityClassConstructorCheck</key> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.design.FinalClassCheck</key> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.UpperEllCheck</key> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.coding.EmptyStatementCheck</key> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.imports.AvoidStarImportCheck</key> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.whitespace.ParenPadCheck</key> <parameters> <parameter> <key>tokens</key> <value>CTOR_CALL,LPAREN,METHOD_CALL,RPAREN,SUPER_CTOR_CALL</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.blocks.NeedBracesCheck</key> <parameters> <parameter> <key>tokens</key> <value>LITERAL_DO,LITERAL_ELSE,LITERAL_IF,LITERAL_FOR,LITERAL_WHILE</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.imports.UnusedImportsCheck</key> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.naming.StaticVariableNameCheck</key> <parameters> <parameter> <key>format</key> <value>^[a-z][a-zA-Z0-9]*$</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.imports.IllegalImportCheck</key> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.naming.MethodNameCheck</key> <parameters> <parameter> <key>format</key> <value>^[a-z][a-zA-Z0-9]*$</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.javadoc.JavadocMethodCheck</key> <parameters> <parameter> <key>allowUndeclaredRTE</key> <value>false</value> </parameter> <parameter> <key>allowThrowsTagsForSubclasses</key> <value>false</value> </parameter> <parameter> <key>allowMissingParamTags</key> <value>false</value> </parameter> <parameter> <key>allowMissingThrowsTags</key> <value>false</value> </parameter> <parameter> <key>allowMissingReturnTag</key> <value>false</value> </parameter> <parameter> <key>allowMissingJavadoc</key> <value>false</value> </parameter> <parameter> <key>allowMissingPropertyJavadoc</key> <value>false</value> </parameter> <parameter> <key>tokens</key> <value>METHOD_DEF,CTOR_DEF</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.FinalParametersCheck</key> <parameters> <parameter> <key>tokens</key> <value>METHOD_DEF,CTOR_DEF</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.coding.SimplifyBooleanReturnCheck</key> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.blocks.EmptyBlockCheck</key> <parameters> <parameter> <key>tokens</key> <value> LITERAL_CATCH,LITERAL_DO,LITERAL_ELSE,LITERAL_FINALLY,LITERAL_IF,LITERAL_FOR,LITERAL_TRY,LITERAL_WHILE,INSTANCE_INIT,STATIC_INIT </value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.TodoCommentCheck</key> <parameters> <parameter> <key>format</key> <value>TODO:</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.coding.DoubleCheckedLockingCheck</key> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.coding.EqualsHashCodeCheck</key> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.javadoc.JavadocVariableCheck</key> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.sizes.FileLengthCheck</key> <parameters> <parameter> <key>max</key> <value>2000</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.sizes.ParameterNumberCheck</key> <parameters> <parameter> <key>max</key> <value>7</value> </parameter> <parameter> <key>tokens</key> <value>METHOD_DEF,CTOR_DEF</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.modifier.RedundantModifierCheck</key> <parameters> <parameter> <key>tokens</key> <value>METHOD_DEF,VARIABLE_DEF,ANNOTATION_FIELD_DEF</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.coding.RedundantThrowsCheck</key> <parameters> <parameter> <key>allowUnchecked</key> <value>false</value> </parameter> <parameter> <key>allowSubclasses</key> <value>false</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.whitespace.TypecastParenPadCheck</key> <parameters> <parameter> <key>tokens</key> <value>TYPECAST,RPAREN</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.sizes.LineLengthCheck</key> <parameters> <parameter> <key>ignorePattern</key> <value>^$</value> </parameter> <parameter> <key>max</key> <value>80</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.coding.InnerAssignmentCheck</key> <parameters> <parameter> <key>tokens</key> <value> ASSIGN,BAND_ASSIGN,BOR_ASSIGN,BSR_ASSIGN,BXOR_ASSIGN,DIV_ASSIGN,MINUS_ASSIGN,MOD_ASSIGN,PLUS_ASSIGN,SL_ASSIGN,SR_ASSIGN,STAR_ASSIGN </value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.whitespace.OperatorWrapCheck</key> <parameters> <parameter> <key>option</key> <value>nl</value> </parameter> <parameter> <key>tokens</key> <value> BAND,BOR,BSR,BXOR,COLON,DIV,EQUAL,GE,GT,LAND,LE,LITERAL_INSTANCEOF,LOR,LT,MINUS,MOD,NOT_EQUAL,PLUS,QUESTION,SL,SR,STAR </value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.naming.MemberNameCheck</key> <parameters> <parameter> <key>format</key> <value>^[a-z][a-zA-Z0-9]*$</value> </parameter> <parameter> <key>applyToPublic</key> <value>true</value> </parameter> <parameter> <key>applyToProtected</key> <value>true</value> </parameter> <parameter> <key>applyToPackage</key> <value>true</value> </parameter> <parameter> <key>applyToPrivate</key> <value>true</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.blocks.RightCurlyCheck</key> <parameters> <parameter> <key>tokens</key> <value>LITERAL_TRY,LITERAL_CATCH,LITERAL_FINALLY,LITERAL_IF,LITERAL_ELSE</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.naming.PackageNameCheck</key> <parameters> <parameter> <key>format</key> <value>^[a-z]+(\.[a-zA-Z_][a-zA-Z0-9_]*)*$</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.naming.ConstantNameCheck</key> <parameters> <parameter> <key>format</key> <value>^[A-Z][A-Z0-9]*(_[A-Z0-9]+)*$</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.naming.TypeNameCheck</key> <parameters> <parameter> <key>format</key> <value>^[A-Z][a-zA-Z0-9]*$</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.sizes.MethodLengthCheck</key> <parameters> <parameter> <key>max</key> <value>150</value> </parameter> <parameter> <key>countEmpty</key> <value>true</value> </parameter> <parameter> <key>tokens</key> <value>METHOD_DEF,CTOR_DEF</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.naming.LocalFinalVariableNameCheck</key> <parameters> <parameter> <key>format</key> <value>^[a-z][a-zA-Z0-9]*$</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.javadoc.JavadocTypeCheck</key> <parameters> <parameter> <key>allowMissingParamTags</key> <value>false</value> </parameter> <parameter> <key>tokens</key> <value>INTERFACE_DEF,CLASS_DEF</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.javadoc.JavadocStyleCheck</key> <parameters> <parameter> <key>checkFirstSentence</key> <value>true</value> </parameter> <parameter> <key>checkEmptyJavadoc</key> <value>false</value> </parameter> <parameter> <key>checkHtml</key> <value>true</value> </parameter> <parameter> <key>tokens</key> <value>INTERFACE_DEF,CLASS_DEF,METHOD_DEF,CTOR_DEF,VARIABLE_DEF</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.design.InterfaceIsTypeCheck</key> <parameters> <parameter> <key>allowMarkerInterfaces</key> <value>true</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.coding.HiddenFieldCheck</key> <parameters> <parameter> <key>tokens</key> <value>PARAMETER_DEF,VARIABLE_DEF</value> </parameter> <parameter> <key>ignoreConstructorParameter</key> <value>false</value> </parameter> <parameter> <key>ignoreSetter</key> <value>false</value> </parameter> <parameter> <key>ignoreAbstractMethods</key> <value>false</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.coding.AvoidInlineConditionalsCheck</key> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.whitespace.NoWhitespaceAfterCheck</key> <parameters> <parameter> <key>allowLineBreaks</key> <value>true</value> </parameter> <parameter> <key>tokens</key> <value>ARRAY_INIT,BNOT,DEC,DOT,INC,LNOT,UNARY_MINUS,UNARY_PLUS</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.blocks.LeftCurlyCheck</key> <parameters> <parameter> <key>option</key> <value>eol</value> </parameter> <parameter> <key>maxLineLength</key> <value>80</value> </parameter> <parameter> <key>tokens</key> <value> CLASS_DEF,CTOR_DEF,INTERFACE_DEF,LITERAL_CATCH,LITERAL_DO,LITERAL_ELSE,LITERAL_FINALLY,LITERAL_FOR,LITERAL_IF,LITERAL_SWITCH,LITERAL_SYNCHRONIZED,LITERAL_TRY,LITERAL_WHILE,METHOD_DEF </value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.design.VisibilityModifierCheck</key> <parameters> <parameter> <key>packageAllowed</key> <value>false</value> </parameter> <parameter> <key>protectedAllowed</key> <value>false</value> </parameter> <parameter> <key>publicMemberPattern</key> <value>^serialVersionUID$</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.naming.ParameterNameCheck</key> <parameters> <parameter> <key>format</key> <value>^[a-z][a-zA-Z0-9]*$</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.whitespace.NoWhitespaceBeforeCheck</key> <parameters> <parameter> <key>allowLineBreaks</key> <value>false</value> </parameter> <parameter> <key>tokens</key> <value>SEMI,POST_DEC,POST_INC</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.whitespace.MethodParamPadCheck</key> <parameters> <parameter> <key>allowLineBreaks</key> <value>false</value> </parameter> <parameter> <key>tokens</key> <value>CTOR_DEF,LITERAL_NEW,METHOD_CALL,METHOD_DEF,SUPER_CTOR_CALL</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.coding.MagicNumberCheck</key> <parameters> <parameter> <key>tokens</key> <value>NUM_DOUBLE,NUM_FLOAT,NUM_INT,NUM_LONG</value> </parameter> <parameter> <key>ignoreNumbers</key> <value>-1,0,1,2</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.naming.LocalVariableNameCheck</key> <parameters> <parameter> <key>format</key> <value>^[a-z][a-zA-Z0-9]*$</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.blocks.AvoidNestedBlocksCheck</key> <parameters> <parameter> <key>allowInSwitchCase</key> <value>false</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.whitespace.WhitespaceAroundCheck</key> <parameters> <parameter> <key>tokens</key> <value> ASSIGN,BAND,BAND_ASSIGN,BOR,BOR_ASSIGN,BSR,BSR_ASSIGN,BXOR,BXOR_ASSIGN,COLON,DIV,DIV_ASSIGN,EQUAL,GE,GT,LAND,LCURLY,LE,LITERAL_ASSERT,LITERAL_CATCH,LITERAL_DO,LITERAL_ELSE,LITERAL_FINALLY,LITERAL_FOR,LITERAL_IF,LITERAL_RETURN,LITERAL_SYNCHRONIZED,LITERAL_TRY,LITERAL_WHILE,LOR,LT,MINUS,MINUS_ASSIGN,MOD,MOD_ASSIGN,NOT_EQUAL,PLUS,PLUS_ASSIGN,QUESTION,RCURLY,SL,SLIST,SL_ASSIGN,SR,SR_ASSIGN,STAR,STAR_ASSIGN,GENERIC_START,GENERIC_END,TYPE_EXTENSION_AND,WILDCARD_TYPE </value> </parameter> <parameter> <key>allowEmptyConstructors</key> <value>false</value> </parameter> <parameter> <key>allowEmptyMethods</key> <value>false</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.ArrayTypeStyleCheck</key> <parameters> <parameter> <key>javaStyle</key> <value>true</value> </parameter> </parameters> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.naming.ClassTypeParameterNameCheck</key> </rule> <rule> <repositoryKey>checkstyle</repositoryKey> <key>com.puppycrawl.tools.checkstyle.checks.naming.MethodTypeParameterNameCheck</key> </rule> </rules> </profile>