Groovy 1.7.10

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

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

    public class AssertionRewriter
    extends StatementReplacingVisitorSupport

Rewrites all assertions in a source unit.

Authors:
  Peter Niederwieser

Method Summary
`protected SourceUnit` | `getSourceUnit()`
`static void` | `rewrite(SourceUnit sourceUnit)` Rewrites all assertions in the given source unit.
`void` | `visitAssertStatement(AssertStatement stat)`
`void` | `visitClass(ClassNode node)`
`void` | `visitClosureExpression(ClosureExpression expr)`
`void` | `visitConstructor(ConstructorNode constructor)`
`void` | `visitMethod(MethodNode method)`

Methods inherited from class StatementReplacingVisitorSupport
replace, replaceAll, replaceVisitedStatementWith, visitBlockStatement, visitCaseStatement, visitCatchStatement, visitDoWhileLoop, visitForLoop, visitIfElse, visitSwitch, visitSynchronizedStatement, visitTryCatchFinally, visitWhileLoop

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

### getSourceUnit

    @Override
    protected SourceUnit getSourceUnit()

### rewrite

    public static void rewrite(SourceUnit sourceUnit)

  Rewrites all assertions in the given source unit.
  Parameters:
    `sourceUnit` - a source unit

### visitAssertStatement

    @Override
    public void visitAssertStatement(AssertStatement stat)

### visitClass

    @Override
    @SuppressWarnings("unchecked")
    public void visitClass(ClassNode node)

### visitClosureExpression

    @Override
    public void visitClosureExpression(ClosureExpression expr)

### visitConstructor

    @Override
    public void visitConstructor(ConstructorNode constructor)

### visitMethod

    @Override
    public void visitMethod(MethodNode method)

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