protected static class Advice.Dispatcher.Delegating.Resolved.AdviceMethodWriter.ForMethodEnter extends Advice.Dispatcher.Delegating.Resolved.AdviceMethodWriter implements Advice.Dispatcher.Bound.ForMethodEnter
Advice.Dispatcher.Delegating.Resolved.AdviceMethodWriter.ForMethodEnter, Advice.Dispatcher.Delegating.Resolved.AdviceMethodWriter.ForMethodExit
Advice.Dispatcher.Bound.ForMethodEnter, Advice.Dispatcher.Bound.ForMethodExit, Advice.Dispatcher.Bound.SkipHandler
adviceMethod, argumentHandler, implementationContext, instrumentedMethod, methodSizeHandler, methodVisitor, stackMapFrameHandler
Modifier | Constructor and Description |
---|---|
protected |
ForMethodEnter(MethodDescription.InDefinedShape adviceMethod,
MethodDescription instrumentedMethod,
List<Advice.OffsetMapping.Target> offsetMappings,
MethodVisitor methodVisitor,
Implementation.Context implementationContext,
Advice.ArgumentHandler.ForAdvice argumentHandler,
Advice.MethodSizeHandler.ForAdvice methodSizeHandler,
Advice.StackMapFrameHandler.ForAdvice stackMapFrameHandler,
Advice.Dispatcher.SuppressionHandler.Bound suppressionHandler,
Advice.Dispatcher.Resolved.ForMethodEnter.SkipDispatcher skipDispatcher)
Creates a new advice method writer.
|
Modifier and Type | Method and Description |
---|---|
void |
apply(Advice.Dispatcher.Bound.SkipHandler skipHandler)
Applies this dispatcher.
|
void |
onDefaultValue(MethodVisitor methodVisitor)
Instructs this return value producer to assure the production of a default value for the return type of the currently handled method.
|
protected void |
onMethodReturn()
Invoked directly after the advice method was called.
|
doApply, prepare
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
prepare
protected ForMethodEnter(MethodDescription.InDefinedShape adviceMethod, MethodDescription instrumentedMethod, List<Advice.OffsetMapping.Target> offsetMappings, MethodVisitor methodVisitor, Implementation.Context implementationContext, Advice.ArgumentHandler.ForAdvice argumentHandler, Advice.MethodSizeHandler.ForAdvice methodSizeHandler, Advice.StackMapFrameHandler.ForAdvice stackMapFrameHandler, Advice.Dispatcher.SuppressionHandler.Bound suppressionHandler, Advice.Dispatcher.Resolved.ForMethodEnter.SkipDispatcher skipDispatcher)
adviceMethod
- The advice method.instrumentedMethod
- The instrumented method.offsetMappings
- The offset mappings available to this advice.methodVisitor
- The method visitor for writing the instrumented method.implementationContext
- The implementation context to use.argumentHandler
- A handler for accessing values on the local variable array.methodSizeHandler
- A handler for computing the method size requirements.stackMapFrameHandler
- A handler for translating and injecting stack map frames.suppressionHandler
- A bound suppression handler that is used for suppressing exceptions of this advice method.skipDispatcher
- The skip dispatcher to use.protected void onMethodReturn()
Advice.Dispatcher.Delegating.Resolved.AdviceMethodWriter
onMethodReturn
in class Advice.Dispatcher.Delegating.Resolved.AdviceMethodWriter
public void apply(Advice.Dispatcher.Bound.SkipHandler skipHandler)
Advice.Dispatcher.Bound.ForMethodEnter
apply
in interface Advice.Dispatcher.Bound.ForMethodEnter
skipHandler
- The skip handler to use.public void onDefaultValue(MethodVisitor methodVisitor)
Advice.Dispatcher.SuppressionHandler.ReturnValueProducer
onDefaultValue
in interface Advice.Dispatcher.SuppressionHandler.ReturnValueProducer
methodVisitor
- The method visitor to write the default value to.Copyright © 2014–2018. All rights reserved.