## org.codehaus.groovy.control
Class LabelVerifier

    java.lang.Object
      org.codehaus.groovy.ast.CodeVisitorSupport
          org.codehaus.groovy.ast.ClassCodeVisitorSupport
              org.codehaus.groovy.control.LabelVerifier

All Implemented Interfaces:
  GroovyClassVisitor, GroovyCodeVisitor

    public class LabelVerifier

extends ClassCodeVisitorSupport

This class checks the handling of labels in the AST

Author:
  Jochen Theodorou

Constructor Summary
`LabelVerifier(SourceUnit src)`

Method Summary
`protected void` `assertNoLabelsMissed()`
`protected SourceUnit` `getSourceUnit()`
`void` `visitBreakStatement(BreakStatement statement)`
`protected void` `visitClassCodeContainer(Statement code)`
`void` `visitContinueStatement(ContinueStatement statement)`
`void` `visitDoWhileLoop(DoWhileStatement loop)`
`void` `visitForLoop(ForStatement forLoop)`
`void` `visitStatement(Statement statement)`
`void` `visitSwitch(SwitchStatement statement)`
`void` `visitWhileLoop(WhileStatement loop)`

Methods inherited from class org.codehaus.groovy.ast.ClassCodeVisitorSupport
`addError, visitAnnotations, visitAssertStatement, visitBlockStatement, visitCaseStatement, visitCatchStatement, visitClass, visitConstructor, visitConstructorOrMethod, visitExpressionStatement, visitField, visitIfElse, visitMethod, visitProperty, visitReturnStatement, visitSynchronizedStatement, visitThrowStatement, visitTryCatchFinally`

Methods inherited from class org.codehaus.groovy.ast.CodeVisitorSupport

`visitArgumentlistExpression, visitArrayExpression, visitAttributeExpression, visitBinaryExpression, visitBitwiseNegationExpression, visitBooleanExpression, visitCastExpression, visitClassExpression, visitClosureExpression, visitClosureListExpression, visitConstantExpression, visitConstructorCallExpression, visitDeclarationExpression, visitFieldExpression, visitGStringExpression, visitListExpression, visitListOfExpressions, visitMapEntryExpression, visitMapExpression, visitMethodCallExpression, visitMethodPointerExpression, visitNotExpression, visitPostfixExpression, visitPrefixExpression, visitPropertyExpression, visitRangeExpression, visitRegexExpression, visitShortTernaryExpression, visitSpreadExpression, visitSpreadMapExpression, visitStaticMethodCallExpression, visitTernaryExpression, visitTupleExpression, visitUnaryMinusExpression, visitUnaryPlusExpression, visitVariableExpression`

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

Constructor Detail

### LabelVerifier

    public LabelVerifier(SourceUnit src)

Method Detail

### getSourceUnit

    protected SourceUnit getSourceUnit()

  Specified by:
    `getSourceUnit` in class `ClassCodeVisitorSupport`

### visitClassCodeContainer

    protected void visitClassCodeContainer(Statement code)

  Overrides:
    `visitClassCodeContainer` in class `ClassCodeVisitorSupport`

### visitStatement

    public void visitStatement(Statement statement)

  Overrides:
    `visitStatement` in class `ClassCodeVisitorSupport`

### visitForLoop

    public void visitForLoop(ForStatement forLoop)

  Specified by:
    `visitForLoop` in interface `GroovyCodeVisitor`
  Overrides:
    `visitForLoop` in class `ClassCodeVisitorSupport`

### visitDoWhileLoop

    public void visitDoWhileLoop(DoWhileStatement loop)

  Specified by:
    `visitDoWhileLoop` in interface `GroovyCodeVisitor`
  Overrides:
    `visitDoWhileLoop` in class `ClassCodeVisitorSupport`

### visitWhileLoop

    public void visitWhileLoop(WhileStatement loop)

  Specified by:
    `visitWhileLoop` in interface `GroovyCodeVisitor`
  Overrides:
    `visitWhileLoop` in class `ClassCodeVisitorSupport`

### visitBreakStatement

    public void visitBreakStatement(BreakStatement statement)

  Specified by:
    `visitBreakStatement` in interface `GroovyCodeVisitor`
  Overrides:
    `visitBreakStatement` in class `ClassCodeVisitorSupport`

### visitContinueStatement

    public void visitContinueStatement(ContinueStatement statement)

  Specified by:
    `visitContinueStatement` in interface `GroovyCodeVisitor`
  Overrides:
    `visitContinueStatement` in class `ClassCodeVisitorSupport`

### assertNoLabelsMissed

    protected void assertNoLabelsMissed()

### visitSwitch

    public void visitSwitch(SwitchStatement statement)

  Specified by:
    `visitSwitch` in interface `GroovyCodeVisitor`
  Overrides:
    `visitSwitch` in class `ClassCodeVisitorSupport`

Copyright © 2003-2008 The Codehaus. All rights reserved.