Package org.codehaus.groovy.control.customizers

## Class DelegatingCustomizer

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

- All Implemented Interfaces:
    `CompilationUnitAware`
  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 org.codehaus.groovy.control.CompilationUnit.PrimaryClassNodeOperation

      `needSortedInput`

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

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

- - ### 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 class `CompilationUnit.PrimaryClassNodeOperation`
      Throws:
        `CompilationFailedException`