Top Description Inners Methods
org.easymock.bytebuddy.implementation.bind.annotation

public @Interface SuperMethodHandle

extends Annotation
Annotations
@Documented
@Retention:RUNTIME
@Target:PARAMETER
Imports
org.easymock.bytebuddy.description.annotation.AnnotationDescription, org.easymock.bytebuddy.description.method.MethodDescription, .MethodList, .ParameterDescription, org.easymock.bytebuddy.description.type.TypeDescription, org.easymock.bytebuddy.implementation.Implementation, org.easymock.bytebuddy.implementation.bind.MethodDelegationBinder, org.easymock.bytebuddy.implementation.bytecode.assign.Assigner, org.easymock.bytebuddy.implementation.bytecode.constant.NullConstant, org.easymock.bytebuddy.utility.JavaType, java.lang.annotation.*

A parameter with this annotation is assigned an instance of java.lang.invoke.MethodHandle which invokes the super implementation of this method. If such a method is not available, this annotation causes that this delegation target cannot be bound unless SuperMethodHandle#nullIfImpossible() is set to true.
See Also
net.bytebuddy.implementation.MethodDelegation, TargetMethodAnnotationDrivenBinder

Nested and Inner Type Summary

Modifier and TypeClass and Description
public static enum
SuperMethodHandle.Binder

A binder for the SuperMethodHandle annotation.

Method Summary

Modifier and TypeMethod and Description
public boolean

Returns:

true if a default method should be invoked if it is not ambiguous and no super class method is available.
fallbackToDefault
()

Indicates that the assigned method should attempt the invocation of an unambiguous default method if no super method is available.

public boolean

Returns:

true if null should be assigned if no valid method can be assigned.
nullIfImpossible
()

Indicates that null should be assigned to this parameter if no super method is invokable.

Inherited from java.lang.annotation.Annotation:
annotationTypeequalshashCodetoString

Method Detail

fallbackToDefaultback to summary
public boolean fallbackToDefault()

Indicates that the assigned method should attempt the invocation of an unambiguous default method if no super method is available.

Returns:boolean

true if a default method should be invoked if it is not ambiguous and no super class method is available.

nullIfImpossibleback to summary
public boolean nullIfImpossible()

Indicates that null should be assigned to this parameter if no super method is invokable.

Returns:boolean

true if null should be assigned if no valid method can be assigned.

org.easymock.bytebuddy.implementation.bind.annotation back to summary

public final Enum SuperMethodHandle.Binder

extends Enum<SuperMethodHandle.Binder>
implements TargetMethodAnnotationDrivenBinder.ParameterBinder<SuperMethodHandle>
Class Inheritance
All Implemented Interfaces
org.easymock.bytebuddy.implementation.bind.annotation.TargetMethodAnnotationDrivenBinder.ParameterBinder

A binder for the SuperMethodHandle annotation.

Field Summary

Modifier and TypeField and Description
private static final MethodDescription.InDefinedShape
public static final SuperMethodHandle.Binder
INSTANCE

The singleton instance.

private static final MethodDescription.InDefinedShape

Constructor Summary

AccessConstructor and Description
private

Method Summary

Modifier and TypeMethod and Description
public MethodDelegationBinder.ParameterBinding<?>
bind(AnnotationDescription.Loadable<SuperMethodHandle>
The annotation that was cause for the delegation to this argument binder.
annotation
,
MethodDescription
The intercepted source method.
source
,
ParameterDescription
Tge target parameter that is subject to be bound to intercepting the source method.
target
,
Implementation.Target
The target of the current implementation that is subject to this binding.
implementationTarget
,
Assigner
An assigner that can be used for applying the binding.
assigner
,
Assigner.Typing
The typing to apply.
typing
)

Implements org.easymock.bytebuddy.implementation.bind.annotation.TargetMethodAnnotationDrivenBinder.ParameterBinder.bind.

Creates a parameter binding for the given target parameter.
public Class<SuperMethodHandle>
public static SuperMethodHandle.Binder
public static SuperMethodHandle.Binder[]
Inherited from java.lang.Enum:
clonecompareTodescribeConstableequalsfinalizegetDeclaringClasshashCodenameordinaltoStringvalueOf

Field Detail

FALLBACK_TO_DEFAULTback to summary
private static final MethodDescription.InDefinedShape FALLBACK_TO_DEFAULT

A description of the SuperMethodHandle#fallbackToDefault() method.

INSTANCEback to summary
public static final SuperMethodHandle.Binder INSTANCE

The singleton instance.

NULL_IF_IMPOSSIBLEback to summary
private static final MethodDescription.InDefinedShape NULL_IF_IMPOSSIBLE

A description of the SuperMethodHandle#nullIfImpossible() method.

Constructor Detail

Binderback to summary
private Binder()

Method Detail

bindback to summary
public MethodDelegationBinder.ParameterBinding<?> bind(AnnotationDescription.Loadable<SuperMethodHandle> annotation, MethodDescription source, ParameterDescription target, Implementation.Target implementationTarget, Assigner assigner, Assigner.Typing typing)

Implements org.easymock.bytebuddy.implementation.bind.annotation.TargetMethodAnnotationDrivenBinder.ParameterBinder.bind.

Doc from org.easymock.bytebuddy.implementation.bind.annotation.TargetMethodAnnotationDrivenBinder.ParameterBinder.bind.

Creates a parameter binding for the given target parameter.

Parameters
annotation:AnnotationDescription.Loadable<SuperMethodHandle>

The annotation that was cause for the delegation to this argument binder.

source:MethodDescription

The intercepted source method.

target:ParameterDescription

Tge target parameter that is subject to be bound to intercepting the source method.

implementationTarget:Implementation.Target

The target of the current implementation that is subject to this binding.

assigner:Assigner

An assigner that can be used for applying the binding.

typing:Assigner.Typing

The typing to apply.

Returns:MethodDelegationBinder.ParameterBinding<?>

A parameter binding for the requested target method parameter.

getHandledTypeback to summary
public Class<SuperMethodHandle> getHandledType()

Implements org.easymock.bytebuddy.implementation.bind.annotation.TargetMethodAnnotationDrivenBinder.ParameterBinder.getHandledType.

Doc from org.easymock.bytebuddy.implementation.bind.annotation.TargetMethodAnnotationDrivenBinder.ParameterBinder.getHandledType.

The annotation type that is handled by this parameter binder.

Returns:Class<SuperMethodHandle>

The java.lang.annotation.Annotation#annotationType() handled by this parameter binder.

valueOfback to summary
public static SuperMethodHandle.Binder valueOf(String name)
valuesback to summary
public static SuperMethodHandle.Binder[] values()