@HashCodeAndEqualsPlugin.Enhance protected static class ConstructorStrategy.Default.WithMethodAttributeAppenderFactory extends java.lang.Object implements ConstructorStrategy
ConstructorStrategy.Default, ConstructorStrategy.ForDefaultConstructor
Modifier and Type | Field and Description |
---|---|
private ConstructorStrategy.Default |
delegate
The delegate default constructor strategy.
|
private MethodAttributeAppender.Factory |
methodAttributeAppenderFactory
The method attribute appender factory to apply.
|
Modifier | Constructor and Description |
---|---|
protected |
WithMethodAttributeAppenderFactory(ConstructorStrategy.Default delegate,
MethodAttributeAppender.Factory methodAttributeAppenderFactory)
Creates a new wrapper for a default constructor strategy.
|
Modifier and Type | Method and Description |
---|---|
java.util.List<MethodDescription.Token> |
extractConstructors(TypeDescription instrumentedType)
Extracts constructors for a given super type.
|
MethodRegistry |
inject(TypeDescription instrumentedType,
MethodRegistry methodRegistry)
Returns a method registry that is capable of creating byte code for the constructors that were
provided by the
ConstructorStrategy.extractConstructors(TypeDescription)
method of this instance. |
private final ConstructorStrategy.Default delegate
private final MethodAttributeAppender.Factory methodAttributeAppenderFactory
protected WithMethodAttributeAppenderFactory(ConstructorStrategy.Default delegate, MethodAttributeAppender.Factory methodAttributeAppenderFactory)
delegate
- The delegate default constructor strategy.methodAttributeAppenderFactory
- The method attribute appender factory to apply.public java.util.List<MethodDescription.Token> extractConstructors(TypeDescription instrumentedType)
extractConstructors
in interface ConstructorStrategy
instrumentedType
- The type for which the constructors should be created.public MethodRegistry inject(TypeDescription instrumentedType, MethodRegistry methodRegistry)
ConstructorStrategy.extractConstructors(TypeDescription)
method of this instance.inject
in interface ConstructorStrategy
instrumentedType
- The instrumented type.methodRegistry
- The original method registry.