## com.puppycrawl.tools.checkstyle.checks.naming
Class ClassTypeParameterNameCheck

    java.lang.Object
      com.puppycrawl.tools.checkstyle.api.AutomaticBean
          com.puppycrawl.tools.checkstyle.api.AbstractViolationReporter
              com.puppycrawl.tools.checkstyle.api.Check
                  com.puppycrawl.tools.checkstyle.checks.AbstractFormatCheck
                      com.puppycrawl.tools.checkstyle.checks.naming.AbstractNameCheck
                          com.puppycrawl.tools.checkstyle.checks.naming.AbstractTypeParameterNameCheck
                              com.puppycrawl.tools.checkstyle.checks.naming.ClassTypeParameterNameCheck

All Implemented Interfaces:
  Configurable, Contextualizable

    public class ClassTypeParameterNameCheck

extends AbstractTypeParameterNameCheck

Checks that class type parameter names conform to a format specified by the format property. The format is a `regular expression` and defaults to ^[A-Z]$.

An example of how to configure the check is:

     <module name="ClassTypeParameterName"/>

An example of how to configure the check for names that are only a single letter is

     <module name="ClassTypeParameterName">
        <property name="format" value="^[a-zA-Z]$"/>
     </module>

Version:
  1.0
Author:
  Travis Schneeberger

Constructor Summary
`ClassTypeParameterNameCheck()` Creates a new `ClassTypeParameterNameCheck` instance.

Method Summary
`protected int` `getLocation()` This method must be overriden to specify the location of the type parameter to check.

Methods inherited from class com.puppycrawl.tools.checkstyle.checks.naming.AbstractTypeParameterNameCheck
`getDefaultTokens, init, mustCheckName`

Methods inherited from class com.puppycrawl.tools.checkstyle.checks.naming.AbstractNameCheck
`visitToken`

Methods inherited from class com.puppycrawl.tools.checkstyle.checks.AbstractFormatCheck
`getFormat, getRegexp, setCompileFlags, setFormat`

Methods inherited from class com.puppycrawl.tools.checkstyle.api.Check
`beginTree, destroy, finishTree, getAcceptableTokens, getClassLoader, getFileContents, getLines, getRequiredTokens, getTabWidth, getTokenNames, leaveToken, log, log, setClassLoader, setFileContents, setMessages, setTabWidth, setTokens`

Methods inherited from class com.puppycrawl.tools.checkstyle.api.AbstractViolationReporter
`getCustomMessages, getId, getMessageBundle, getSeverity, getSeverityLevel, log, setId, setSeverity`

Methods inherited from class com.puppycrawl.tools.checkstyle.api.AutomaticBean
`configure, contextualize, finishLocalSetup, getConfiguration, setupChild`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### ClassTypeParameterNameCheck

    public ClassTypeParameterNameCheck()

  Creates a new `ClassTypeParameterNameCheck` instance.

Method Detail

### getLocation

    protected final int getLocation()

  Description copied from class: `AbstractTypeParameterNameCheck`
  This method must be overriden to specify the location of the type parameter to check.

  Specified by:
    `getLocation` in class `AbstractTypeParameterNameCheck`
  Returns:
    `TokenTypes.CLASS_DEF` or `TokenTypes.METHOD_DEF`

Copyright © 2001-2011. All Rights Reserved.