com.puppycrawl.tools.checkstyle.checks.naming

Class MethodNameCheck

public class MethodNameCheck extends AbstractNameCheck

Checks that method names conform to a format specified by the format property. The format is a {@link java.util.regex.Pattern regular expression} and defaults to ^[a-z][a-zA-Z0-9]*$.

An example of how to configure the check is:

 <module name="MethodName"/>
 

An example of how to configure the check for names that begin with a lower case letter, followed by letters, digits, and underscores is:

 <module name="MethodName">
    <property name="format" value="^[a-z](_?[a-zA-Z0-9]+)*$"/>
 </module>
 

Version: 1.0

Author: Oliver Burn

Constructor Summary
MethodNameCheck()
Creates a new MethodNameCheck instance.
Method Summary
int[]getDefaultTokens()
{@inheritDoc}

Constructor Detail

MethodNameCheck

public MethodNameCheck()
Creates a new MethodNameCheck instance.

Method Detail

getDefaultTokens

public int[] getDefaultTokens()
{@inheritDoc}