Package: org.apache.groovy.contracts.ast

## [Java] Class GContractsASTTransformation

- org.apache.groovy.contracts.ast.GContractsASTTransformation

-     @GroovyASTTransformation(phase = CompilePhase.INSTRUCTION_SELECTION)
      public class GContractsASTTransformation
      extends BaseASTTransformation

  Custom AST transformation that removes closure annotations of Invariant, Requires and Ensures and adds Java assertions executing the closure-code.

  Whenever an assertion is broken an AssertionViolation descendant class will be thrown.

  See Also:
    PreconditionViolation
    PostconditionViolation
    ClassInvariantViolation

- - ### Methods Summary

    Methods
    Type Params | Return Type | Name and description
    --- | --- | ---
    `` | `public void` | `visit(ASTNode[] nodes, SourceUnit unit)` ASTTransformation.visit

- - ### Method Detail

    - #### @Override
      public void visit(ASTNode[] nodes, SourceUnit unit)

      ASTTransformation.visit