Package: org.codehaus.groovy.control

## [Java] Interface CompilationUnit.ISourceUnitOperation

- org.codehaus.groovy.control.CompilationUnit.PhaseOperation

- All Superinterfaces:
    CompilationUnit.PhaseOperation

      @FunctionalInterface
      public interface CompilationUnit.ISourceUnitOperation
      extends CompilationUnit.PhaseOperation

  Performs an operation for each source unit in the compilation.

- - ### Methods Summary

    Methods
    Type Params | Return Type | Name and description
    --- | --- | ---
    `` | `public void` | `call(SourceUnit source)` Performs the operation for one source unit.
    `` | `public void` | `doPhaseOperation(CompilationUnit unit)` A loop driver for applying operations to all SourceUnits.

  - ### Inherited Methods Summary

    Inherited Methods
    Methods inherited from class | Name
    --- | ---
    `interface CompilationUnit.PhaseOperation` | `doPhaseOperation`

- - ### Method Detail

    - #### public void call(SourceUnit source)

      Performs the operation for one source unit.

      throws:
        CompilationFailedException if processing fails
      Parameters:
        `source` - the source unit to process

    - #### public void doPhaseOperation(CompilationUnit unit)

      A loop driver for applying operations to all SourceUnits. Automatically skips units that have already been processed through the current phase.