Package: org.codehaus.groovy.classgen.asm

## [Java] Class AssertionWriter

- org.codehaus.groovy.classgen.asm.AssertionWriter

-     public class AssertionWriter
      extends Object

  Emits bytecode for Groovy `assert` statements.

- - ### Constructor Summary

    Constructors
    Constructor and description
    `AssertionWriter(WriterController wc)` Creates an assertion writer for the supplied controller.

  - ### Methods Summary

    Methods
    Type Params | Return Type | Name and description
    --- | --- | ---
    `` | `public void` | `disableTracker()` Temporarily disables power-assert value tracking.
    `` | `public void` | `record(Token token)` Records the current stack value for the supplied token position.
    `` | `public void` | `record(Expression expression)` Records the current stack value for the supplied expression position.
    `` | `public void` | `reenableTracker()` Restores power-assert value tracking after a previous disable.
    `` | `public void` | `writeAssertStatement(AssertStatement statement)` Emits bytecode for an `assert` statement.

  - ### Inherited Methods Summary

    Inherited Methods
    Methods inherited from class | Name
    --- | ---
    `class Object` | `equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### public AssertionWriter(WriterController wc)

      Creates an assertion writer for the supplied controller.

      Parameters:
        `wc` - the active writer controller

  - ### Method Detail

    - #### public void disableTracker()

      Temporarily disables power-assert value tracking.

    - #### public void record(Token token)

      Records the current stack value for the supplied token position.

      Parameters:
        `token` - the token whose source position should be recorded

    - #### public void record(Expression expression)

      Records the current stack value for the supplied expression position.

      Parameters:
        `expression` - the expression whose source position should be recorded

    - #### public void reenableTracker()

      Restores power-assert value tracking after a previous disable.

    - #### public void writeAssertStatement(AssertStatement statement)

      Emits bytecode for an `assert` statement.

      Parameters:
        `statement` - the assertion statement