Package org.codehaus.groovy.control.customizers

## Class DelegatingCustomizer

- java.lang.Object
- - org.codehaus.groovy.control.customizers.CompilationCustomizer
  - - org.codehaus.groovy.control.customizers.DelegatingCustomizer

- All Implemented Interfaces:
    `CompilationUnitAware`, `CompilationUnit.IPrimaryClassNodeOperation`
  Direct Known Subclasses:
    `SourceAwareCustomizer`

      public abstract class DelegatingCustomizer
      extends CompilationCustomizer
      implements CompilationUnitAware

  Base class for compilation customizers which delegate to another customizer. The phase this customizer runs at is retrieved from the phase of the delegate.
  Since:
    2.1.0

- - ### Field Summary

    Fields
    Modifier and Type | Field | Description
    --- | --- | ---
    `protected CompilationCustomizer` | `delegate` |

  - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `DelegatingCustomizer​(CompilationCustomizer delegate)` |

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `void` | `call​(SourceUnit source, GeneratorContext context, ClassNode classNode)` |
    `void` | `setCompilationUnit​(CompilationUnit compilationUnit)` |

    - ### Methods inherited from class org.codehaus.groovy.control.customizers.CompilationCustomizer

      `getPhase`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

    - ### Methods inherited from interface org.codehaus.groovy.control.CompilationUnit.IPrimaryClassNodeOperation

      `doPhaseOperation, needSortedInput`

- - ### Field Detail

    - #### delegate

          protected final CompilationCustomizer delegate

  - ### Constructor Detail

    - #### DelegatingCustomizer

          public DelegatingCustomizer​(CompilationCustomizer delegate)

  - ### Method Detail

    - #### setCompilationUnit

          public void setCompilationUnit​(CompilationUnit compilationUnit)

      Specified by:
        `setCompilationUnit` in interface `CompilationUnitAware`

    - #### call

          public void call​(SourceUnit source,
                           GeneratorContext context,
                           ClassNode classNode)
                    throws CompilationFailedException

      Specified by:
        `call` in interface `CompilationUnit.IPrimaryClassNodeOperation`
      Throws:
        `CompilationFailedException`