Interface StackManipulation
-
- All Known Subinterfaces:
ArrayFactory.ArrayCreator,Implementation.SpecialMethodInvocation,MethodConstant.CanCache,MethodDelegationBinder.MethodBinding,MethodDelegationBinder.ParameterBinding<T>,MethodInvocation.WithImplicitInvocationTargetType
- All Known Implementing Classes:
Addition,ArrayAccess.Loader,ArrayAccess.Putter,ArrayFactory.ArrayCreator.ForPrimitiveType,ArrayFactory.ArrayCreator.ForReferenceType,ArrayFactory.ArrayStackManipulation,ClassConstant,ClassConstant.ForReferenceType,DefaultMethod.Binder.DelegationMethod,DefaultValue,DoubleConstant,DoubleConstant.ConstantPool,Duplication,Duplication.WithFlip,EqualsMethod.ConditionalReturn,EqualsMethod.NullValueGuard.UsingJump.AfterInstruction,EqualsMethod.NullValueGuard.UsingJump.BeforeInstruction,EqualsMethod.ValueComparator,FieldAccess.AccessDispatcher.AbstractFieldInstruction,FieldAccess.AccessDispatcher.FieldGetInstruction,FieldAccess.AccessDispatcher.FieldPutInstruction,FieldConstant,FieldConstant.Cached,FieldProxy.Binder.AccessorProxy,FloatConstant,FloatConstant.ConstantPool,HandleInvocation,HashCodeMethod.NullValueGuard.UsingJump.AfterInstruction,HashCodeMethod.NullValueGuard.UsingJump.BeforeInstruction,HashCodeMethod.ValueTransformer,Implementation.Context.Default.FieldCacheEntry,Implementation.SpecialMethodInvocation.AbstractBase,Implementation.SpecialMethodInvocation.Illegal,Implementation.SpecialMethodInvocation.Simple,InstanceCheck,IntegerConstant,IntegerConstant.ConstantPool,IntegerConstant.SingleBytePush,IntegerConstant.TwoBytePush,JavaConstantValue,LongConstant,LongConstant.ConstantPool,MethodCallProxy.AssignableSignatureCall,MethodConstant,MethodConstant.CachedConstructor,MethodConstant.CachedMethod,MethodConstant.CanCacheIllegal,MethodConstant.ForConstructor,MethodConstant.ForMethod,MethodConstant.PrivilegedLookup,MethodDelegationBinder.MethodBinding.Builder.Build,MethodDelegationBinder.MethodBinding.Illegal,MethodDelegationBinder.ParameterBinding.Anonymous,MethodDelegationBinder.ParameterBinding.Illegal,MethodDelegationBinder.ParameterBinding.Unique,MethodInvocation.DynamicInvocation,MethodInvocation.HandleInvocation,MethodInvocation.IllegalInvocation,MethodInvocation.Invocation,MethodInvocation.OfGenericMethod,MethodReturn,MethodVariableAccess.MethodLoading,MethodVariableAccess.OffsetIncrementing,MethodVariableAccess.OffsetLoading,MethodVariableAccess.OffsetWriting,Morph.Binder.RedirectionProxy,Multiplication,NullConstant,Pipe.Binder.Redirection,PrimitiveBoxingDelegate.BoxingStackManipulation,PrimitiveUnboxingDelegate,PrimitiveWideningDelegate.WideningStackManipulation,RebaseImplementationTarget.RebasedMethodInvocation,Removal,SerializedConstant,StackManipulation.Compound,StackManipulation.Illegal,StackManipulation.Trivial,SuperMethod.Binder.DelegationMethod,TextConstant,Throw,ToStringMethod.ValueConsumer,TypeCasting,TypeCreation,TypeProxy.AbstractMethodErrorThrow,TypeProxy.ForDefaultMethod,TypeProxy.ForSuperMethodByConstructor,TypeProxy.ForSuperMethodByReflectionFactory,TypeProxy.MethodCall.Appender.AccessorMethodInvocation
public interface StackManipulationDescribes a manipulation of a method's operand stack that does not affect the frame's variable array.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static classStackManipulation.CompoundAn immutable stack manipulation that aggregates a sequence of other stack manipulations.static classStackManipulation.IllegalCanonical representation of an illegal stack manipulation.static classStackManipulation.SizeA description of the size change that is imposed by someStackManipulation.static classStackManipulation.TrivialCanonical representation of a legal stack manipulation which does not require any action.
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description StackManipulation.Sizeapply(org.objectweb.asm.MethodVisitor methodVisitor, Implementation.Context implementationContext)Applies the stack manipulation that is described by this instance.booleanisValid()Determines if this stack manipulation is valid.
-
-
-
Method Detail
-
isValid
boolean isValid()
Determines if this stack manipulation is valid.- Returns:
- If
false, this manipulation cannot be applied and should throw an exception.
-
apply
StackManipulation.Size apply(org.objectweb.asm.MethodVisitor methodVisitor, Implementation.Context implementationContext)
Applies the stack manipulation that is described by this instance.- Parameters:
methodVisitor- The method visitor used to write the method implementation to.implementationContext- The context of the current implementation.- Returns:
- The changes to the size of the operand stack that are implied by this stack manipulation.
-
-