Package net.bytebuddy.agent.builder
Class AgentBuilder.Transformer.ForAdvice.Entry.ForUnifiedAdvice
java.lang.Object
net.bytebuddy.agent.builder.AgentBuilder.Transformer.ForAdvice.Entry
net.bytebuddy.agent.builder.AgentBuilder.Transformer.ForAdvice.Entry.ForUnifiedAdvice
- Enclosing class:
AgentBuilder.Transformer.ForAdvice.Entry
@Enhance
protected static class AgentBuilder.Transformer.ForAdvice.Entry.ForUnifiedAdvice
extends AgentBuilder.Transformer.ForAdvice.Entry
An entry for an advice class where both the (optional) entry and exit advice methods are declared by the same class.
-
Nested Class Summary
Nested classes/interfaces inherited from class net.bytebuddy.agent.builder.AgentBuilder.Transformer.ForAdvice.Entry
AgentBuilder.Transformer.ForAdvice.Entry.ForSplitAdvice, AgentBuilder.Transformer.ForAdvice.Entry.ForUnifiedAdvice
-
Field Summary
Fields -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotected
ForUnifiedAdvice
(LatentMatcher<? super MethodDescription> matcher, String name) Creates a new entry for an advice class where both the (optional) entry and exit advice methods are declared by the same class. -
Method Summary
Modifier and TypeMethodDescriptionprotected Advice
resolve
(Advice.WithCustomMapping advice, TypePool typePool, ClassFileLocator classFileLocator) Resolves the advice for this entry.Methods inherited from class net.bytebuddy.agent.builder.AgentBuilder.Transformer.ForAdvice.Entry
getMatcher
-
Field Details
-
name
The name of the advice class.
-
-
Constructor Details
-
ForUnifiedAdvice
Creates a new entry for an advice class where both the (optional) entry and exit advice methods are declared by the same class.- Parameters:
matcher
- The matcher for advised methods.name
- The name of the advice class.
-
-
Method Details
-
resolve
protected Advice resolve(Advice.WithCustomMapping advice, TypePool typePool, ClassFileLocator classFileLocator) Description copied from class:AgentBuilder.Transformer.ForAdvice.Entry
Resolves the advice for this entry.- Specified by:
resolve
in classAgentBuilder.Transformer.ForAdvice.Entry
- Parameters:
advice
- The advice configuration.typePool
- The type pool to use.classFileLocator
- The class file locator to use.- Returns:
- The resolved advice.
-