Class Transformer.Compound<S>

  • Type Parameters:
    S - The type of the transformed instance.
    All Implemented Interfaces:
    Transformer<S>
    Enclosing interface:
    Transformer<T>

    @Enhance
    public static class Transformer.Compound<S>
    extends java.lang.Object
    implements Transformer<S>
    A compound transformer.
    • Field Detail

      • transformers

        private final java.util.List<Transformer<S>> transformers
        The list of transformers to apply in their application order.
    • Constructor Detail

      • Compound

        public Compound​(Transformer<S>... transformer)
        Creates a new compound transformer.
        Parameters:
        transformer - The list of transformers to apply in their application order.
      • Compound

        public Compound​(java.util.List<? extends Transformer<S>> transformers)
        Creates a new compound transformer.
        Parameters:
        transformers - The list of transformers to apply in their application order.
    • Method Detail

      • transform

        public S transform​(TypeDescription instrumentedType,
                           S target)
        Transforms the supplied target.
        Specified by:
        transform in interface Transformer<S>
        Parameters:
        instrumentedType - The instrumented type that declares the target being transformed.
        target - The target entity that is being transformed.
        Returns:
        The transformed instance.