Class ConstructorStrategy.Default.WithMethodAttributeAppenderFactory

  • All Implemented Interfaces:
    ConstructorStrategy
    Enclosing class:
    ConstructorStrategy.Default

    protected static class ConstructorStrategy.Default.WithMethodAttributeAppenderFactory
    extends java.lang.Object
    implements ConstructorStrategy
    A wrapper for a default constructor strategy which additionally applies a method attribute appender factory.
    • Constructor Detail

      • WithMethodAttributeAppenderFactory

        protected WithMethodAttributeAppenderFactory​(ConstructorStrategy.Default delegate,
                                                     MethodAttributeAppender.Factory methodAttributeAppenderFactory)
        Creates a new wrapper for a default constructor strategy.
        Parameters:
        delegate - The delegate default constructor strategy.
        methodAttributeAppenderFactory - The method attribute appender factory to apply.
    • Method Detail

      • extractConstructors

        public java.util.List<MethodDescription.Token> extractConstructors​(TypeDescription instrumentedType)
        Description copied from interface: ConstructorStrategy
        Extracts constructors for a given super type. The extracted constructor signatures will then be imitated by the created dynamic type.
        Specified by:
        extractConstructors in interface ConstructorStrategy
        Parameters:
        instrumentedType - The type for which the constructors should be created.
        Returns:
        A list of tokens that describe the constructors that are to be implemented.