Groovy 1.7.10

## org.codehaus.groovy.transform.powerassert
[Java] Class StatementReplacingVisitorSupport

    java.lang.Object
      org.codehaus.groovy.ast.CodeVisitorSupport
          org.codehaus.groovy.ast.ClassCodeVisitorSupport
              org.codehaus.groovy.transform.powerassert.StatementReplacingVisitorSupport

    public abstract class StatementReplacingVisitorSupport
    extends ClassCodeVisitorSupport

Adds the ability to replace statements.

Authors:
  Peter Niederwieser

Method Summary
`Statement` | `replace(Statement stat)` Visits the specified statement.
`protected void` | `replaceAll(List stats)` Visits the statements in the specified mutable list.
`protected void` | `replaceVisitedStatementWith(Statement other)` Replaces the currently visited statement with the specified statement.
`void` | `visitBlockStatement(BlockStatement stat)`
`void` | `visitCaseStatement(CaseStatement stat)`
`void` | `visitCatchStatement(CatchStatement stat)`
`void` | `visitDoWhileLoop(DoWhileStatement stat)`
`void` | `visitForLoop(ForStatement stat)`
`void` | `visitIfElse(IfStatement stat)`
`void` | `visitSwitch(SwitchStatement stat)`
`void` | `visitSynchronizedStatement(SynchronizedStatement stat)`
`void` | `visitTryCatchFinally(TryCatchStatement stat)`
`void` | `visitWhileLoop(WhileStatement stat)`

Methods inherited from class ClassCodeVisitorSupport

addError, getSourceUnit, visitAnnotations, visitAssertStatement, visitBlockStatement, visitBreakStatement, visitCaseStatement, visitCatchStatement, visitClass, visitClassCodeContainer, visitConstructor, visitConstructorOrMethod, visitContinueStatement, visitDoWhileLoop, visitExpressionStatement, visitField, visitForLoop, visitIfElse, visitImports, visitMethod, visitObjectInitializerStatements, visitPackage, visitProperty, visitReturnStatement, visitStatement, visitSwitch, visitSynchronizedStatement, visitThrowStatement, visitTryCatchFinally, visitVariableExpression, visitWhileLoop

Methods inherited from class CodeVisitorSupport

visitArgumentlistExpression, visitArrayExpression, visitAssertStatement, visitAttributeExpression, visitBinaryExpression, visitBitwiseNegationExpression, visitBlockStatement, visitBooleanExpression, visitBreakStatement, visitBytecodeExpression, visitCaseStatement, visitCastExpression, visitCatchStatement, visitClassExpression, visitClosureExpression, visitClosureListExpression, visitConstantExpression, visitConstructorCallExpression, visitContinueStatement, visitDeclarationExpression, visitDoWhileLoop, visitEmptyStatement, visitExpressionStatement, visitFieldExpression, visitForLoop, visitGStringExpression, visitIfElse, visitListExpression, visitListOfExpressions, visitMapEntryExpression, visitMapExpression, visitMethodCallExpression, visitMethodPointerExpression, visitNotExpression, visitPostfixExpression, visitPrefixExpression, visitPropertyExpression, visitRangeExpression, visitRegexExpression, visitReturnStatement, visitShortTernaryExpression, visitSpreadExpression, visitSpreadMapExpression, visitStaticMethodCallExpression, visitSwitch, visitSynchronizedStatement, visitTernaryExpression, visitThrowStatement, visitTryCatchFinally, visitTupleExpression, visitUnaryMinusExpression, visitUnaryPlusExpression, visitVariableExpression, visitWhileLoop

Methods inherited from class Object
wait, wait, wait, equals, toString, hashCode, getClass, notify, notifyAll

Method Detail

### replace

    public Statement replace(Statement stat)

  Visits the specified statement. If the statement's visit method calls replaceVisitedMethodWith(), the statement will be replaced.

### replaceAll

    @SuppressWarnings("unchecked")
    protected void replaceAll(List stats)

  Visits the statements in the specified mutable list. If a statement's visit method calls replaceVisitedMethodWith(), the statement will be replaced.

### replaceVisitedStatementWith

    protected void replaceVisitedStatementWith(Statement other)

  Replaces the currently visited statement with the specified statement.

### visitBlockStatement

    @Override
    public void visitBlockStatement(BlockStatement stat)

### visitCaseStatement

    @Override
    public void visitCaseStatement(CaseStatement stat)

### visitCatchStatement

    @Override
    public void visitCatchStatement(CatchStatement stat)

### visitDoWhileLoop

    @Override
    public void visitDoWhileLoop(DoWhileStatement stat)

### visitForLoop

    @Override
    public void visitForLoop(ForStatement stat)

### visitIfElse

    @Override
    public void visitIfElse(IfStatement stat)

### visitSwitch

    @Override
    public void visitSwitch(SwitchStatement stat)

### visitSynchronizedStatement

    @Override
    public void visitSynchronizedStatement(SynchronizedStatement stat)

### visitTryCatchFinally

    @Override
    public void visitTryCatchFinally(TryCatchStatement stat)

### visitWhileLoop

    @Override
    public void visitWhileLoop(WhileStatement stat)

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