Class MemberNameCheck

  • All Implemented Interfaces:
    Configurable, Contextualizable

    public class MemberNameCheck
    extends AbstractAccessControlNameCheck

    Checks that instance variable names conform to a specified pattern.

    • Property applyToPackage - Controls whether to apply the check to package-private member. Type is boolean. Default value is true.
    • Property applyToPrivate - Controls whether to apply the check to private member. Type is boolean. Default value is true.
    • Property applyToProtected - Controls whether to apply the check to protected member. Type is boolean. Default value is true.
    • Property applyToPublic - Controls whether to apply the check to public member. Type is boolean. Default value is true.
    • Property format - Specifies valid identifiers. Type is java.util.regex.Pattern. Default value is "^[a-z][a-zA-Z0-9]*$".

    Parent is com.puppycrawl.tools.checkstyle.TreeWalker

    Violation Message Keys:

    • name.invalidPattern
    Since:
    3.0