Class NestedForDepthCheck

  • All Implemented Interfaces:
    Configurable, Contextualizable

    public final class NestedForDepthCheck
    extends AbstractCheck
    Restricts nested for blocks to a specified depth.
    • Property max - Specify maximum allowed nesting depth. Type is int. Default value is 1.

    Parent is com.puppycrawl.tools.checkstyle.TreeWalker

    Violation Message Keys:

    • nested.for.depth
    Since:
    5.3