InterfaceTypeParameterName: enabled

This commit is contained in:
Paul Campbell 2016-09-06 20:22:52 +01:00
parent aed8ec658c
commit d3136df134
2 changed files with 16 additions and 5 deletions

View file

@ -164,7 +164,7 @@ You need to include `checkstyle` as the version bundled with the `maven-checksty
* [InnerClass](#innerclass) - sevntu - disabled * [InnerClass](#innerclass) - sevntu - disabled
* [InnerTypeLast](#innertypelast) - checkstyle - enabled * [InnerTypeLast](#innertypelast) - checkstyle - enabled
* [InterfaceIsType](#interfaceistype) - checkstyle - enabled * [InterfaceIsType](#interfaceistype) - checkstyle - enabled
* [InterfaceTypeParameterName](#interfacetypeparametername) - checkstyle - disabled * [InterfaceTypeParameterName](#interfacetypeparametername) - checkstyle - enabled
* [InterfaceTypeParameterName](#interfacetypeparametername-1) - sevntu - disabled * [InterfaceTypeParameterName](#interfacetypeparametername-1) - sevntu - disabled
* [JavadocMethod](#javadocmethod) - checkstyle - enabled * [JavadocMethod](#javadocmethod) - checkstyle - enabled
* [JavadocPackage](#javadocpackage) - checkstyle - enabled * [JavadocPackage](#javadocpackage) - checkstyle - enabled
@ -1259,6 +1259,20 @@ interface Foo {
} }
```` ````
#### [InterfaceTypeParameterName](http://checkstyle.sourceforge.net/config_naming.html#InterfaceTypeParameterName)
Checks that the type parameters for an interface are a single uppercase letter.
Valid:
````
interface <T> Portable {}
````
Invalid:
````
interface <Type> Portable {}
````
#### [JavadocMethod](http://checkstyle.sourceforge.net/config_javadoc.html#JavadocMethod) #### [JavadocMethod](http://checkstyle.sourceforge.net/config_javadoc.html#JavadocMethod)
Checks that all public, protected and package methods have a Javadoc block, that all `@throws` tags are used. Basic setters and getters do not require javadoc. Checks that all public, protected and package methods have a Javadoc block, that all `@throws` tags are used. Basic setters and getters do not require javadoc.
@ -2661,10 +2675,6 @@ Generic rule; doesn't embody a 'quality' check.
Couldn't get my IDE's (IntelliJ) code style to match. Couldn't get my IDE's (IntelliJ) code style to match.
#### [InterfaceTypeParameterName](http://checkstyle.sourceforge.net/config_naming.html#InterfaceTypeParameterName)
> TODO: enable
#### [JavadocTagContinuationIndentation](http://checkstyle.sourceforge.net/config_javadoc.html#JavadocTagContinuationIndentation) #### [JavadocTagContinuationIndentation](http://checkstyle.sourceforge.net/config_javadoc.html#JavadocTagContinuationIndentation)
Couldn't get my IDE's (IntelliJ) code style to match. Couldn't get my IDE's (IntelliJ) code style to match.

View file

@ -104,6 +104,7 @@
<module name="InnerAssignment"/> <!-- prevent assignments in subexpressions (i.e. while((line = read()){}) --> <module name="InnerAssignment"/> <!-- prevent assignments in subexpressions (i.e. while((line = read()){}) -->
<module name="InnerTypeLast"/> <!-- inner classes appear after methods and fields --> <module name="InnerTypeLast"/> <!-- inner classes appear after methods and fields -->
<module name="InterfaceIsType"/> <!-- interface must define method not just constants --> <module name="InterfaceIsType"/> <!-- interface must define method not just constants -->
<module name="InterfaceTypeParameterName"/> <!-- interface generic type is a single uppercase letter -->
<module name="JavadocMethod"> <!-- methods should have javadoc block --> <module name="JavadocMethod"> <!-- methods should have javadoc block -->
<property name="scope" value="package"/> <!-- if they are public, protected or package --> <property name="scope" value="package"/> <!-- if they are public, protected or package -->