| Package | Description |
|---|---|
| net.bytebuddy |
Byte Buddy is a library for creating Java classes at runtime of a Java program.
|
| net.bytebuddy.agent.builder |
An agent builder is used to easily implement load-time class-transformations using a Java agent.
|
| net.bytebuddy.description |
Classes of this package allow the representation of Java classes, their member and their meta data.
|
| net.bytebuddy.description.annotation |
Contains descriptions of annotations and annotation values.
|
| net.bytebuddy.description.enumeration |
A package that contains classes for describing enumeration values.
|
| net.bytebuddy.description.field |
Contains descriptions of Java fields.
|
| net.bytebuddy.description.method |
Contains descriptions of Java methods and constructors as well as their parameters.
|
| net.bytebuddy.description.type |
Contains descriptions of Java types and packages.
|
| net.bytebuddy.dynamic |
This package contains classes and interfaces that are connected to writing the byte stream that represents a Java
type that is dynamically created and for loading this type into a running JVM process.
|
| net.bytebuddy.dynamic.loading |
This package contains classes that are responsible for class loading of classes that are represented by
byte arrays. |
| net.bytebuddy.dynamic.scaffold |
This package contains helper types and implementations that are responsible for the actual writing of a byte array
representing a Java class.
|
| net.bytebuddy.dynamic.scaffold.inline |
All classes and types in this package are related to creating a
DynamicType by
enhancing a given type. |
| net.bytebuddy.dynamic.scaffold.subclass |
All classes and types in this package are related to creating a
DynamicType by
creating a subclass of a given type. |
| net.bytebuddy.implementation |
The implementation package contains any logic for intercepting method calls.
|
| net.bytebuddy.implementation.attribute |
All types and classes in this package are responsible for writing attributes for a given Java byte code element,
i.e.
|
| net.bytebuddy.implementation.auxiliary |
Auxiliary types describe helper types that aid as a supplementary to a given
InstrumentedType. |
| net.bytebuddy.implementation.bind |
The types and classes of this package are responsible for binding a method call to calling another method.
|
| net.bytebuddy.implementation.bind.annotation |
This package contains annotations, types and classes that are responsible for binding a method to calling another
method by interpreting annotations that indicate how a method should be bound to another method.
|
| net.bytebuddy.implementation.bytecode |
Types and classes in this package are responsible for creating Java byte code for a given byte code target
which is represented by a
MethodDescription. |
| net.bytebuddy.implementation.bytecode.assign |
An
Assigner is responsible for transforming
a given TypeDescription into another one. |
| net.bytebuddy.implementation.bytecode.assign.primitive |
Assigner implementations of this package
are capable of handling primitive types or the void type. |
| net.bytebuddy.implementation.bytecode.assign.reference |
Assigner implementations of this package
are capable of assigning non-primitive types to each other. |
| net.bytebuddy.implementation.bytecode.collection |
This package is dedicated to creating
StackManipulations
that create collections or arrays from a given number of values. |
| net.bytebuddy.implementation.bytecode.constant |
StackManipulations in this package are responsible for
creating compile-time constants and pushing them onto the operand stack. |
| net.bytebuddy.implementation.bytecode.member |
StackManipulations of this package are responsible for
accessing type or method members, i.e. |
| net.bytebuddy.matcher |
Contains an API for matching Java byte code entities.
|
| net.bytebuddy.pool |
Classes of this package allow for the creating
TypeDescriptions without
loading any classes. |
| net.bytebuddy.utility |
This package contains utility classes for common use within any Byte Buddy logic.
|
| Modifier and Type | Field and Description |
|---|---|
protected List<TypeDescription> |
ByteBuddy.interfaceTypes
A list of interface types to be implemented by any class that is implemented by the current configuration.
|
| Modifier and Type | Method and Description |
|---|---|
TypeDescription |
NamingStrategy.UnnamedType.getSuperClass()
Returns this unnamed type's super class.
|
TypeDescription |
NamingStrategy.UnnamedType.Default.getSuperClass() |
| Modifier and Type | Method and Description |
|---|---|
Collection<TypeDescription> |
NamingStrategy.UnnamedType.getDeclaredInterfaces()
Returns a collection of descriptions of this unnamed type's directly implemented interfaces.
|
List<TypeDescription> |
NamingStrategy.UnnamedType.Default.getDeclaredInterfaces() |
List<TypeDescription> |
ByteBuddy.getInterfaceTypes()
Returns the naming strategy for the current configuration.
|
List<TypeDescription> |
ByteBuddy.Proxy.getInterfaceTypes() |
| Modifier and Type | Method and Description |
|---|---|
DynamicType.Builder<?> |
ByteBuddy.makeInterface(TypeDescription... typeDescription)
Creates a dynamic type builder for an interface that extends a number of given interfaces.
|
NamingStrategy |
NamingStrategy.Unbound.rebase(TypeDescription typeDescription)
Returns a naming strategy for rebasing a type.
|
NamingStrategy |
NamingStrategy.Unbound.Default.rebase(TypeDescription typeDescription) |
NamingStrategy |
NamingStrategy.Unbound.Unified.rebase(TypeDescription typeDescription) |
<T> DynamicType.Builder<T> |
ByteBuddy.rebase(TypeDescription levelType,
ClassFileLocator classFileLocator)
Creates a dynamic type by weaving any changes into an already defined level type.
|
<T> DynamicType.Builder<T> |
ByteBuddy.Proxy.rebase(TypeDescription levelType,
ClassFileLocator classFileLocator) |
<T> DynamicType.Builder<T> |
ByteBuddy.rebase(TypeDescription levelType,
ClassFileLocator classFileLocator,
MethodRebaseResolver.MethodNameTransformer methodNameTransformer)
Creates a dynamic type by weaving any changes into an already defined level type.
|
<T> DynamicType.Builder<T> |
ByteBuddy.Proxy.rebase(TypeDescription levelType,
ClassFileLocator classFileLocator,
MethodRebaseResolver.MethodNameTransformer methodNameTransformer) |
NamingStrategy |
NamingStrategy.Unbound.redefine(TypeDescription typeDescription)
Returns a naming strategy for redefining a type.
|
NamingStrategy |
NamingStrategy.Unbound.Default.redefine(TypeDescription typeDescription) |
NamingStrategy |
NamingStrategy.Unbound.Unified.redefine(TypeDescription typeDescription) |
<T> DynamicType.Builder<T> |
ByteBuddy.redefine(TypeDescription levelType,
ClassFileLocator classFileLocator)
Creates a dynamic type builder for redefining of the given type.
|
<T> DynamicType.Builder<T> |
ByteBuddy.Proxy.redefine(TypeDescription levelType,
ClassFileLocator classFileLocator) |
NamingStrategy |
NamingStrategy.Unbound.subclass(TypeDescription typeDescription)
Returns a naming strategy for subclassing a type.
|
NamingStrategy |
NamingStrategy.Unbound.Default.subclass(TypeDescription typeDescription) |
NamingStrategy |
NamingStrategy.Unbound.Unified.subclass(TypeDescription typeDescription) |
<T> DynamicType.Builder<T> |
ByteBuddy.subclass(TypeDescription superType)
Creates a dynamic type builder that creates a subclass of a given type description where the subclass
is created by the
ConstructorStrategy.Default.IMITATE_SUPER_TYPE
strategy. |
<T> DynamicType.Builder<T> |
ByteBuddy.Proxy.subclass(TypeDescription superType) |
<T> DynamicType.Builder<T> |
ByteBuddy.subclass(TypeDescription superType,
ConstructorStrategy constructorStrategy)
Creates a dynamic type builder that creates a subclass of a given type description.
|
<T> DynamicType.Builder<T> |
ByteBuddy.Proxy.subclass(TypeDescription superType,
ConstructorStrategy constructorStrategy) |
ByteBuddy.OptionalMethodInterception |
ByteBuddy.withImplementing(TypeDescription... type)
Defines all dynamic types that are created by this configuration to implement the given interfaces.
|
ByteBuddy.OptionalMethodInterception |
ByteBuddy.Proxy.withImplementing(TypeDescription... type) |
| Modifier and Type | Method and Description |
|---|---|
DynamicType.Builder<?> |
ByteBuddy.makeInterface(Collection<? extends TypeDescription> typeDescriptions)
Creates a dynamic type builder for an interface that extends a number of given interfaces.
|
DynamicType.Builder<?> |
ByteBuddy.Proxy.makeInterface(Collection<? extends TypeDescription> typeDescriptions) |
ByteBuddy.OptionalMethodInterception |
ByteBuddy.withImplementing(Collection<? extends TypeDescription> types)
Defines all dynamic types that are created by this configuration to implement the given interfaces.
|
ByteBuddy.OptionalMethodInterception |
ByteBuddy.Proxy.withImplementing(Collection<? extends TypeDescription> types) |
| Constructor and Description |
|---|
Default(TypeDescription superClass,
List<TypeDescription> interfaces,
int modifiers,
ClassFileVersion classFileVersion)
Creates a new unnamed type.
|
ForGivenType(TypeDescription typeDescription)
Creates a new base name resolver that resolves a using the name of a given type.
|
ValuesMethodAppender(TypeDescription instrumentedType)
Creates a new appender for the
values method. |
| Constructor and Description |
|---|
ByteBuddy(ClassFileVersion classFileVersion,
NamingStrategy.Unbound namingStrategy,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
List<TypeDescription> interfaceTypes,
ElementMatcher<? super MethodDescription> ignoredMethods,
BridgeMethodResolver.Factory bridgeMethodResolverFactory,
ClassVisitorWrapper.Chain classVisitorWrapperChain,
MethodRegistry methodRegistry,
ByteBuddy.Definable<Integer> modifiers,
TypeAttributeAppender typeAttributeAppender,
MethodLookupEngine.Factory methodLookupEngineFactory,
FieldAttributeAppender.Factory defaultFieldAttributeAppenderFactory,
MethodAttributeAppender.Factory defaultMethodAttributeAppenderFactory)
Defines a new
ByteBuddy configuration. |
Default(TypeDescription superClass,
List<TypeDescription> interfaces,
int modifiers,
ClassFileVersion classFileVersion)
Creates a new unnamed type.
|
MethodAnnotationTarget(ClassFileVersion classFileVersion,
NamingStrategy.Unbound namingStrategy,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
List<TypeDescription> interfaceTypes,
ElementMatcher<? super MethodDescription> ignoredMethods,
BridgeMethodResolver.Factory bridgeMethodResolverFactory,
ClassVisitorWrapper.Chain classVisitorWrapperChain,
MethodRegistry methodRegistry,
ByteBuddy.Definable<Integer> modifiers,
TypeAttributeAppender typeAttributeAppender,
MethodLookupEngine.Factory methodLookupEngineFactory,
FieldAttributeAppender.Factory defaultFieldAttributeAppenderFactory,
MethodAttributeAppender.Factory defaultMethodAttributeAppenderFactory,
LatentMethodMatcher methodMatcher,
MethodRegistry.Handler handler,
MethodAttributeAppender.Factory attributeAppenderFactory)
Creates a new method annotation target.
|
OptionalMethodInterception(ClassFileVersion classFileVersion,
NamingStrategy.Unbound namingStrategy,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
List<TypeDescription> interfaceTypes,
ElementMatcher<? super MethodDescription> ignoredMethods,
BridgeMethodResolver.Factory bridgeMethodResolverFactory,
ClassVisitorWrapper.Chain classVisitorWrapperChain,
MethodRegistry methodRegistry,
ByteBuddy.Definable<Integer> modifiers,
TypeAttributeAppender typeAttributeAppender,
MethodLookupEngine.Factory methodLookupEngineFactory,
FieldAttributeAppender.Factory defaultFieldAttributeAppenderFactory,
MethodAttributeAppender.Factory defaultMethodAttributeAppenderFactory,
LatentMethodMatcher methodMatcher)
Creates a new optional method interception.
|
Proxy(ClassFileVersion classFileVersion,
NamingStrategy.Unbound namingStrategy,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
List<TypeDescription> interfaceTypes,
ElementMatcher<? super MethodDescription> ignoredMethods,
BridgeMethodResolver.Factory bridgeMethodResolverFactory,
ClassVisitorWrapper.Chain classVisitorWrapperChain,
MethodRegistry methodRegistry,
ByteBuddy.Definable<Integer> modifiers,
TypeAttributeAppender typeAttributeAppender,
MethodLookupEngine.Factory methodLookupEngineFactory,
FieldAttributeAppender.Factory defaultFieldAttributeAppenderFactory,
MethodAttributeAppender.Factory defaultMethodAttributeAppenderFactory)
Defines a new proxy configuration for
ByteBuddy. |
| Modifier and Type | Method and Description |
|---|---|
ByteCodeAppender |
AgentBuilder.Default.InitializationStrategy.SelfInjection.Nexus.Accessor.initializerFor(TypeDescription instrumentedType)
Creates a stack manipulation for a given instrumented type that injects a code block for
calling the system class loader's nexus in order to apply a self-initialization.
|
boolean |
AgentBuilder.RawMatcher.matches(TypeDescription typeDescription,
ClassLoader classLoader,
Class<?> classBeingRedefined,
ProtectionDomain protectionDomain)
Decides if the given
typeDescription should be instrumented with the entailed
AgentBuilder.Transformers. |
boolean |
AgentBuilder.RawMatcher.ForElementMatcherPair.matches(TypeDescription typeDescription,
ClassLoader classLoader,
Class<?> classBeingRedefined,
ProtectionDomain protectionDomain) |
boolean |
AgentBuilder.Default.Transformation.matches(TypeDescription typeDescription,
ClassLoader classLoader,
Class<?> classBeingRedefined,
ProtectionDomain protectionDomain) |
void |
AgentBuilder.Listener.onTransformation(TypeDescription typeDescription,
DynamicType dynamicType)
Invoked right before a successful transformation is applied.
|
void |
AgentBuilder.Listener.NoOp.onTransformation(TypeDescription typeDescription,
DynamicType dynamicType) |
void |
AgentBuilder.Listener.Compound.onTransformation(TypeDescription typeDescription,
DynamicType dynamicType) |
DynamicType.Builder<?> |
AgentBuilder.Transformer.transform(DynamicType.Builder<?> builder,
TypeDescription typeDescription)
Allows for a transformation of a
DynamicType.Builder. |
DynamicType.Builder<?> |
AgentBuilder.Transformer.NoOp.transform(DynamicType.Builder<?> builder,
TypeDescription typeDescription) |
DynamicType.Builder<?> |
AgentBuilder.Transformer.Compound.transform(DynamicType.Builder<?> builder,
TypeDescription typeDescription) |
DynamicType.Builder<?> |
AgentBuilder.Default.Transformation.transform(DynamicType.Builder<?> builder,
TypeDescription typeDescription) |
| Modifier and Type | Method and Description |
|---|---|
AgentBuilder.Identified |
AgentBuilder.rebase(ElementMatcher<? super TypeDescription> typeMatcher)
Matches a type being loaded in order to apply the supplied
AgentBuilder.Transformers before loading this type. |
AgentBuilder.Identified |
AgentBuilder.Default.rebase(ElementMatcher<? super TypeDescription> typeMatcher) |
AgentBuilder.Identified |
AgentBuilder.Default.Matched.rebase(ElementMatcher<? super TypeDescription> typeMatcher) |
AgentBuilder.Identified |
AgentBuilder.rebase(ElementMatcher<? super TypeDescription> typeMatcher,
ElementMatcher<? super ClassLoader> classLoaderMatcher)
Matches a type being loaded in order to apply the supplied
AgentBuilder.Transformers before loading this type. |
AgentBuilder.Identified |
AgentBuilder.Default.rebase(ElementMatcher<? super TypeDescription> typeMatcher,
ElementMatcher<? super ClassLoader> classLoaderMatcher) |
AgentBuilder.Identified |
AgentBuilder.Default.Matched.rebase(ElementMatcher<? super TypeDescription> typeMatcher,
ElementMatcher<? super ClassLoader> classLoaderMatcher) |
| Constructor and Description |
|---|
ForElementMatcherPair(ElementMatcher<? super TypeDescription> typeMatcher,
ElementMatcher<? super ClassLoader> classLoaderMatcher)
Creates a new
AgentBuilder.RawMatcher that only matches the
supplied TypeDescription and its
ClassLoader against two matcher in order to decied if an instrumentation should
be conducted. |
| Modifier and Type | Method and Description |
|---|---|
boolean |
ByteCodeElement.isVisibleTo(TypeDescription typeDescription)
Checks if this element is visible from a given type.
|
| Modifier and Type | Field and Description |
|---|---|
protected TypeDescription |
AnnotationDescription.Builder.annotationType
The annotation type.
|
| Modifier and Type | Method and Description |
|---|---|
TypeDescription |
AnnotationDescription.getAnnotationType()
Returns a description of the annotation type of this annotation.
|
TypeDescription |
AnnotationDescription.ForLoadedAnnotation.getAnnotationType() |
TypeDescription |
AnnotationDescription.Latent.getAnnotationType() |
TypeDescription |
AnnotationDescription.Latent.Loadable.getAnnotationType() |
TypeDescription |
AnnotationDescription.AnnotationValue.ForType.resolve() |
| Modifier and Type | Method and Description |
|---|---|
static <V extends Class<V>> |
AnnotationDescription.AnnotationValue.ForType.of(TypeDescription typeDescription)
Creates an annotation value for representing the given type.
|
| Modifier and Type | Method and Description |
|---|---|
AnnotationDescription.Builder |
AnnotationDescription.Builder.define(String property,
TypeDescription typeDescription)
Returns a builder with the additional class property.
|
AnnotationDescription.Builder |
AnnotationDescription.Builder.define(String property,
TypeDescription enumerationType,
String value)
Returns a builder with the additional enumeration property.
|
AnnotationDescription.Builder |
AnnotationDescription.Builder.defineAnnotationArray(String property,
TypeDescription annotationType,
AnnotationDescription... annotationDescription)
Returns a builder with the additional annotation array property.
|
AnnotationDescription.Builder |
AnnotationDescription.Builder.defineEnumerationArray(String property,
TypeDescription enumerationType,
EnumerationDescription... value)
Returns a builder with the additional enumeration array property.
|
AnnotationDescription.Builder |
AnnotationDescription.Builder.defineEnumerationArray(String property,
TypeDescription enumerationType,
String... value)
Returns a builder with the additional enumeration array property.
|
AnnotationDescription.Builder |
AnnotationDescription.Builder.defineTypeArray(String property,
TypeDescription... typeDescription)
Returns a builder with the additional type array property.
|
static Object |
AnnotationDescription.ForLoadedAnnotation.describe(Object value,
TypeDescription typeDescription)
A helper method for converting a loaded type into a representation that is also capable of representing
unloaded descriptions of annotation values as specified by
AnnotationDescription. |
static AnnotationDescription.Builder |
AnnotationDescription.Builder.forType(TypeDescription annotationType)
Creates a builder for creating an annotation of the given type.
|
boolean |
AnnotationList.isAnnotationPresent(TypeDescription annotationType)
Checks if this list contains an annotation of the given type.
|
boolean |
AnnotationList.ForLoadedAnnotation.isAnnotationPresent(TypeDescription annotationType) |
boolean |
AnnotationList.Explicit.isAnnotationPresent(TypeDescription annotationType) |
boolean |
AnnotationList.Empty.isAnnotationPresent(TypeDescription annotationType) |
static <V extends Class<V>> |
AnnotationDescription.AnnotationValue.ForType.of(TypeDescription typeDescription)
Creates an annotation value for representing the given type.
|
static AnnotationDescription.AnnotationValue<TypeDescription[],Class<?>[]> |
AnnotationDescription.AnnotationValue.ForComplexArray.of(TypeDescription[] typeDescription)
Creates a new complex array of annotation descriptions.
|
static <W extends Annotation> |
AnnotationDescription.AnnotationValue.ForComplexArray.of(TypeDescription annotationType,
AnnotationDescription[] annotationDescription)
Creates a new complex array of annotation descriptions.
|
static <W extends Enum<W>> |
AnnotationDescription.AnnotationValue.ForComplexArray.of(TypeDescription enumerationType,
EnumerationDescription[] enumerationDescription)
Creates a new complex array of enumeration descriptions.
|
static <V extends Annotation> |
AnnotationDescription.AnnotationValue.ForAnnotation.of(TypeDescription annotationType,
Map<String,AnnotationDescription.AnnotationValue<?,?>> annotationValues)
Creates an annotation value instance for describing the given annotation type and values.
|
| Modifier and Type | Method and Description |
|---|---|
AnnotationList |
AnnotationList.inherited(Set<? extends TypeDescription> ignoredTypes)
Returns only annotations that are marked as
Inherited as long as they are not
contained by the set of ignored annotation types. |
AnnotationList |
AnnotationList.ForLoadedAnnotation.inherited(Set<? extends TypeDescription> ignoredTypes) |
AnnotationList |
AnnotationList.Explicit.inherited(Set<? extends TypeDescription> ignoredTypes) |
AnnotationList |
AnnotationList.Empty.inherited(Set<? extends TypeDescription> ignoredTypes) |
| Constructor and Description |
|---|
Builder(TypeDescription annotationType,
Map<String,AnnotationDescription.AnnotationValue<?,?>> annotationValues)
Creates a builder for an annotation description.
|
ForComplexArray(Class<?> unloadedComponentType,
TypeDescription componentType,
List<? extends AnnotationDescription.AnnotationValue<?,?>> annotationValues)
Creates a new complex array.
|
ForType(TypeDescription typeDescription)
Creates a new annotation value that represents a type.
|
Latent(TypeDescription annotationType,
Map<String,AnnotationDescription.AnnotationValue<?,?>> annotationValues)
Creates a new latent annotation description.
|
| Modifier and Type | Method and Description |
|---|---|
TypeDescription |
EnumerationDescription.getEnumerationType()
Returns the type of this enumeration.
|
TypeDescription |
EnumerationDescription.ForLoadedEnumeration.getEnumerationType() |
TypeDescription |
EnumerationDescription.Latent.getEnumerationType() |
| Constructor and Description |
|---|
Latent(TypeDescription enumerationType,
String value)
Creates a latent description of an enumeration value.
|
| Modifier and Type | Method and Description |
|---|---|
TypeDescription |
FieldDescription.ForLoadedField.getDeclaringType() |
TypeDescription |
FieldDescription.Latent.getDeclaringType() |
TypeDescription |
FieldDescription.getFieldType()
Returns a description of the type of this field.
|
TypeDescription |
FieldDescription.ForLoadedField.getFieldType() |
TypeDescription |
FieldDescription.Latent.getFieldType() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
FieldDescription.AbstractFieldDescription.isVisibleTo(TypeDescription typeDescription) |
| Constructor and Description |
|---|
Latent(String fieldName,
TypeDescription declaringType,
TypeDescription fieldType,
int modifiers)
Creates an immutable latent field description.
|
| Modifier and Type | Method and Description |
|---|---|
TypeDescription |
MethodDescription.ForLoadedConstructor.getDeclaringType() |
TypeDescription |
MethodDescription.ForLoadedMethod.getDeclaringType() |
TypeDescription |
MethodDescription.Latent.getDeclaringType() |
TypeDescription |
MethodDescription.getReturnType()
Returns a description of the return type of the method described by this instance.
|
TypeDescription |
MethodDescription.ForLoadedConstructor.getReturnType() |
TypeDescription |
MethodDescription.ForLoadedMethod.getReturnType() |
TypeDescription |
MethodDescription.Latent.getReturnType() |
TypeDescription |
ParameterDescription.getTypeDescription()
Returns the parameter's type.
|
TypeDescription |
ParameterDescription.ForLoadedParameter.getTypeDescription() |
TypeDescription |
ParameterDescription.ForLoadedParameter.OfLegacyVmMethod.getTypeDescription() |
TypeDescription |
ParameterDescription.ForLoadedParameter.OfLegacyVmConstructor.getTypeDescription() |
TypeDescription |
ParameterDescription.Latent.getTypeDescription() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
MethodDescription.isInvokableOn(TypeDescription typeDescription)
Asserts if this method is invokable on an instance of the given type, i.e.
|
boolean |
MethodDescription.AbstractMethodDescription.isInvokableOn(TypeDescription typeDescription) |
boolean |
MethodDescription.isSpecializableFor(TypeDescription typeDescription)
Checks if this method can be called using the
INVOKESPECIAL for a given type. |
boolean |
MethodDescription.AbstractMethodDescription.isSpecializableFor(TypeDescription targetType) |
boolean |
MethodDescription.AbstractMethodDescription.isVisibleTo(TypeDescription typeDescription) |
static MethodDescription |
MethodDescription.Latent.typeInitializerOf(TypeDescription declaringType)
Creates a latent method description of a type initializer (
<clinit>) for a given type. |
| Modifier and Type | Method and Description |
|---|---|
static ParameterList |
ParameterList.Explicit.latent(MethodDescription declaringMethod,
List<? extends TypeDescription> parameterTypes)
Creates a list of method parameters from a list of type descriptions.
|
| Constructor and Description |
|---|
Latent(MethodDescription declaringMethod,
TypeDescription parameterType,
int index,
int offset)
Creates a latent description of a parameter.
|
Latent(String internalName,
TypeDescription declaringType,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes,
int modifiers,
List<? extends TypeDescription> exceptionTypes)
Creates an immutable latent method description.
|
| Constructor and Description |
|---|
Latent(String internalName,
TypeDescription declaringType,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes,
int modifiers,
List<? extends TypeDescription> exceptionTypes)
Creates an immutable latent method description.
|
Latent(String internalName,
TypeDescription declaringType,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes,
int modifiers,
List<? extends TypeDescription> exceptionTypes)
Creates an immutable latent method description.
|
| Modifier and Type | Class and Description |
|---|---|
static class |
TypeDescription.AbstractTypeDescription
An abstract base implementation of a type description.
|
static class |
TypeDescription.AbstractTypeDescription.OfSimpleType
An adapter implementation of a
TypeDescription that
describes any type that is not an array or a primitive type. |
static class |
TypeDescription.ArrayProjection
A projection for an array type based on an existing
TypeDescription. |
static class |
TypeDescription.ForLoadedType
A type description implementation that represents a loaded type.
|
static class |
TypeDescription.Latent
A latent type description for a type without methods or fields.
|
| Modifier and Type | Field and Description |
|---|---|
static TypeDescription |
TypeDescription.CLASS
A representation of the
Class type. |
static TypeDescription |
TypeDescription.ENUM
A representation of the
Enum type. |
static TypeDescription |
TypeDescription.OBJECT
A representation of the
Object type. |
static TypeDescription |
TypeDescription.STRING
A representation of the
String type. |
static TypeDescription |
TypeDescription.VOID
A representation of the
void non-type. |
| Modifier and Type | Method and Description |
|---|---|
TypeDescription |
TypeList.ForLoadedType.get(int index) |
TypeDescription |
TypeList.Explicit.get(int index) |
TypeDescription |
TypeDescription.getComponentType()
Returns the component type of this type.
|
TypeDescription |
TypeDescription.AbstractTypeDescription.OfSimpleType.getComponentType() |
TypeDescription |
TypeDescription.ForLoadedType.getComponentType() |
TypeDescription |
TypeDescription.ArrayProjection.getComponentType() |
TypeDescription |
TypeDescription.ForLoadedType.getDeclaringType() |
TypeDescription |
TypeDescription.ArrayProjection.getDeclaringType() |
TypeDescription |
TypeDescription.Latent.getDeclaringType() |
TypeDescription |
DeclaredInType.getDeclaringType()
Returns the declaring type of this instance.
|
TypeDescription |
TypeDescription.getEnclosingType()
Returns a description of the enclosing type of this type.
|
TypeDescription |
TypeDescription.ForLoadedType.getEnclosingType() |
TypeDescription |
TypeDescription.ArrayProjection.getEnclosingType() |
TypeDescription |
TypeDescription.Latent.getEnclosingType() |
TypeDescription |
TypeDescription.getSupertype()
Returns the component type of this type.
|
TypeDescription |
TypeDescription.ForLoadedType.getSupertype() |
TypeDescription |
TypeDescription.ArrayProjection.getSupertype() |
TypeDescription |
TypeDescription.Latent.getSupertype() |
static TypeDescription |
TypeDescription.ArrayProjection.of(TypeDescription componentType,
int arity)
Creates an array projection.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
TypeDescription.isAssignableFrom(TypeDescription typeDescription)
Checks if this type is assignable from the type described by this instance, for example for
class Foo and class Bar extends Foo, this method would return true for
Foo.class.isAssignableFrom(Bar.class). |
boolean |
TypeDescription.AbstractTypeDescription.OfSimpleType.isAssignableFrom(TypeDescription typeDescription) |
boolean |
TypeDescription.ForLoadedType.isAssignableFrom(TypeDescription typeDescription) |
boolean |
TypeDescription.ArrayProjection.isAssignableFrom(TypeDescription typeDescription) |
boolean |
TypeDescription.isAssignableTo(TypeDescription typeDescription)
Checks if this type is assignable from the type described by this instance, for example for
class Foo and class Bar extends Foo, this method would return true for
Bar.class.isAssignableFrom(Foo.class). |
boolean |
TypeDescription.AbstractTypeDescription.OfSimpleType.isAssignableTo(TypeDescription typeDescription) |
boolean |
TypeDescription.ForLoadedType.isAssignableTo(TypeDescription typeDescription) |
boolean |
TypeDescription.ArrayProjection.isAssignableTo(TypeDescription typeDescription) |
boolean |
TypeDescription.isSamePackage(TypeDescription typeDescription)
Checks if two types are defined in the same package.
|
boolean |
TypeDescription.AbstractTypeDescription.isSamePackage(TypeDescription typeDescription) |
boolean |
TypeDescription.AbstractTypeDescription.isVisibleTo(TypeDescription typeDescription) |
static TypeDescription |
TypeDescription.ArrayProjection.of(TypeDescription componentType,
int arity)
Creates an array projection.
|
| Modifier and Type | Method and Description |
|---|---|
protected TypeList |
TypeList.ForLoadedType.wrap(List<TypeDescription> values) |
protected TypeList |
TypeList.Explicit.wrap(List<TypeDescription> values) |
| Constructor and Description |
|---|
ArrayProjection(TypeDescription componentType,
int arity)
Crrates a new array projection.
|
Latent(String name,
int modifiers,
TypeDescription superType,
List<? extends TypeDescription> interfaces)
Creates a new latent type.
|
| Constructor and Description |
|---|
Explicit(List<? extends TypeDescription> typeDescriptions)
Creates an immutable wrapper.
|
Latent(String name,
int modifiers,
TypeDescription superType,
List<? extends TypeDescription> interfaces)
Creates a new latent type.
|
| Modifier and Type | Field and Description |
|---|---|
static TypeDescription |
TargetType.DESCRIPTION
A description representation of the
TargetType. |
protected TypeDescription |
DynamicType.Builder.AbstractBase.FieldToken.fieldType
A description of the field type or a description of the
TargetType placeholder. |
protected TypeDescription |
DynamicType.Builder.AbstractBase.MethodToken.returnType
A description of the return type of the method or a type describing the
TargetType placeholder. |
protected TypeDescription |
DynamicType.Builder.AbstractBase.targetType
The target type description that is specified for this builder.
|
protected TypeDescription |
DynamicType.Default.typeDescription
A type description of this dynamic type.
|
| Modifier and Type | Field and Description |
|---|---|
protected List<TypeDescription> |
DynamicType.Builder.AbstractBase.MethodToken.exceptionTypes
A list of exception type descriptions for the method.
|
protected List<TypeDescription> |
DynamicType.Builder.AbstractBase.interfaceTypes
The interface types to implement as specified for this builder.
|
protected List<TypeDescription> |
DynamicType.Builder.AbstractBase.MethodToken.parameterTypes
A list of parameter type descriptions for the method which might be represented by the
TargetType placeholder. |
| Modifier and Type | Method and Description |
|---|---|
TypeDescription |
DynamicType.Builder.AbstractBase.FieldToken.getFieldType()
Returns the type of this field token.
|
TypeDescription |
DynamicType.Builder.AbstractBase.MethodToken.getReturnType()
Returns a description of the return type of this method token.
|
TypeDescription |
DynamicType.getTypeDescription()
Returns a description of this dynamic type.
|
TypeDescription |
DynamicType.Default.getTypeDescription() |
static TypeDescription |
TargetType.resolve(TypeDescription typeDescription,
TypeDescription actualTargetType)
Resolves the given type description with the actual target type if the
typeDescription resembles the
TargetType placeholder. |
protected TypeDescription |
DynamicType.Builder.AbstractBase.FieldToken.resolveFieldType(TypeDescription instrumentedType)
Resolves the field type which could be represented by the
TargetType placeholder type. |
protected TypeDescription |
DynamicType.Builder.AbstractBase.MethodToken.resolveReturnType(TypeDescription instrumentedType)
Resolves the return type for the method which could be represented by the
TargetType placeholder type. |
| Modifier and Type | Method and Description |
|---|---|
Map<TypeDescription,byte[]> |
DynamicType.getAllTypes()
Returns all types that are implied by this dynamic type.
|
Map<TypeDescription,byte[]> |
DynamicType.Default.getAllTypes() |
List<TypeDescription> |
DynamicType.Builder.AbstractBase.MethodToken.getExceptionTypes()
Returns a list of exception types of this method token.
|
Map<TypeDescription,Class<?>> |
DynamicType.Loaded.getLoadedAuxiliaryTypes()
Returns a map of all loaded auxiliary types to this dynamic type.
|
Map<TypeDescription,Class<?>> |
DynamicType.Default.Loaded.getLoadedAuxiliaryTypes() |
Map<TypeDescription,LoadedTypeInitializer> |
DynamicType.getLoadedTypeInitializers()
Returns a map of all loaded type initializers for the main type and all auxiliary types, if any.
|
Map<TypeDescription,LoadedTypeInitializer> |
DynamicType.Default.getLoadedTypeInitializers() |
List<TypeDescription> |
DynamicType.Builder.AbstractBase.MethodToken.getParameterTypes()
Returns a list of descriptions of the parameter types of this method token.
|
Map<TypeDescription,byte[]> |
DynamicType.getRawAuxiliaryTypes()
Returns a map of all auxiliary types that are required for making use of the main type.
|
Map<TypeDescription,byte[]> |
DynamicType.Default.getRawAuxiliaryTypes() |
protected List<TypeDescription> |
DynamicType.Builder.AbstractBase.MethodToken.resolveExceptionTypes(TypeDescription instrumentedType)
Resolves the declared exception types for the method.
|
protected List<TypeDescription> |
DynamicType.Builder.AbstractBase.MethodToken.resolveParameterTypes(TypeDescription instrumentedType)
Resolves the parameter types for the method which could be represented by the
TargetType placeholder type. |
Map<TypeDescription,File> |
DynamicType.saveIn(File folder)
Saves a dynamic type in a given folder using the Java class file format while respecting the naming conventions
for saving compiled Java classes.
|
Map<TypeDescription,File> |
DynamicType.Default.saveIn(File folder) |
| Modifier and Type | Method and Description |
|---|---|
DynamicType.Builder.FieldValueTarget<T> |
DynamicType.Builder.defineField(String name,
TypeDescription fieldTypeDescription,
int modifiers)
Defines a new field for this type.
|
DynamicType.Builder.FieldValueTarget<S> |
DynamicType.Builder.AbstractBase.defineField(String name,
TypeDescription fieldTypeDescription,
int modifiers) |
DynamicType.Builder.FieldValueTarget<U> |
DynamicType.Builder.AbstractBase.AbstractDelegatingBuilder.defineField(String name,
TypeDescription fieldTypeDescription,
int modifiers) |
DynamicType.Builder.FieldValueTarget<T> |
DynamicType.Builder.defineField(String name,
TypeDescription fieldTypeDescription,
ModifierContributor.ForField... modifier)
Defines a new field for this type.
|
DynamicType.Builder.FieldValueTarget<S> |
DynamicType.Builder.AbstractBase.defineField(String name,
TypeDescription fieldType,
ModifierContributor.ForField... modifier) |
DynamicType.Builder.FieldValueTarget<U> |
DynamicType.Builder.AbstractBase.AbstractDelegatingBuilder.defineField(String name,
TypeDescription fieldTypeDescription,
ModifierContributor.ForField... modifier) |
DynamicType.Builder.ExceptionDeclarableMethodInterception<T> |
DynamicType.Builder.defineMethod(String name,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes,
int modifiers)
Defines a new method for this type.
|
DynamicType.Builder.ExceptionDeclarableMethodInterception<S> |
DynamicType.Builder.AbstractBase.defineMethod(String name,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes,
int modifiers) |
DynamicType.Builder.ExceptionDeclarableMethodInterception<U> |
DynamicType.Builder.AbstractBase.AbstractDelegatingBuilder.defineMethod(String name,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes,
int modifiers) |
DynamicType.Builder.ExceptionDeclarableMethodInterception<T> |
DynamicType.Builder.defineMethod(String name,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes,
ModifierContributor.ForMethod... modifier)
Defines a new method for this type.
|
DynamicType.Builder.ExceptionDeclarableMethodInterception<S> |
DynamicType.Builder.AbstractBase.defineMethod(String name,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes,
ModifierContributor.ForMethod... modifier) |
DynamicType.Builder.ExceptionDeclarableMethodInterception<U> |
DynamicType.Builder.AbstractBase.AbstractDelegatingBuilder.defineMethod(String name,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes,
ModifierContributor.ForMethod... modifier) |
DynamicType.Builder.OptionalMatchedMethodInterception<T> |
DynamicType.Builder.implement(TypeDescription... interfaceType)
Adds the given interfaces to be implemented by the created type.
|
DynamicType.Builder.OptionalMatchedMethodInterception<S> |
DynamicType.Builder.AbstractBase.implement(TypeDescription... interfaceType) |
DynamicType.Builder.OptionalMatchedMethodInterception<U> |
DynamicType.Builder.AbstractBase.AbstractDelegatingBuilder.implement(TypeDescription... interfaceType) |
protected abstract DynamicType.Builder<S> |
DynamicType.Builder.AbstractBase.materialize(ClassFileVersion classFileVersion,
NamingStrategy namingStrategy,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
TypeDescription targetType,
List<TypeDescription> interfaceTypes,
int modifiers,
TypeAttributeAppender attributeAppender,
ElementMatcher<? super MethodDescription> ignoredMethods,
BridgeMethodResolver.Factory bridgeMethodResolverFactory,
ClassVisitorWrapper.Chain classVisitorWrapperChain,
FieldRegistry fieldRegistry,
MethodRegistry methodRegistry,
MethodLookupEngine.Factory methodLookupEngineFactory,
FieldAttributeAppender.Factory defaultFieldAttributeAppenderFactory,
MethodAttributeAppender.Factory defaultMethodAttributeAppenderFactory,
List<DynamicType.Builder.AbstractBase.FieldToken> fieldTokens,
List<DynamicType.Builder.AbstractBase.MethodToken> methodTokens)
Creates a new immutable type builder which represents the given arguments.
|
static DynamicType.Builder.FieldValueTarget.NumericRangeValidator |
DynamicType.Builder.FieldValueTarget.NumericRangeValidator.of(TypeDescription typeDescription)
Identifies the correct validator for a given type description.
|
static TypeList |
TargetType.resolve(List<? extends TypeDescription> typeList,
TypeDescription actualTargetType)
Resolves any type description in the given listwith the actual target type if the
typeDescription resembles the
TargetType placeholder. |
ElementMatcher<? super MethodDescription> |
DynamicType.Builder.AbstractBase.MethodToken.resolve(TypeDescription instrumentedType) |
static TypeDescription |
TargetType.resolve(TypeDescription typeDescription,
TypeDescription actualTargetType)
Resolves the given type description with the actual target type if the
typeDescription resembles the
TargetType placeholder. |
protected List<TypeDescription> |
DynamicType.Builder.AbstractBase.MethodToken.resolveExceptionTypes(TypeDescription instrumentedType)
Resolves the declared exception types for the method.
|
protected TypeDescription |
DynamicType.Builder.AbstractBase.FieldToken.resolveFieldType(TypeDescription instrumentedType)
Resolves the field type which could be represented by the
TargetType placeholder type. |
protected List<TypeDescription> |
DynamicType.Builder.AbstractBase.MethodToken.resolveParameterTypes(TypeDescription instrumentedType)
Resolves the parameter types for the method which could be represented by the
TargetType placeholder type. |
protected TypeDescription |
DynamicType.Builder.AbstractBase.MethodToken.resolveReturnType(TypeDescription instrumentedType)
Resolves the return type for the method which could be represented by the
TargetType placeholder type. |
DynamicType.Builder.MatchedMethodInterception<S> |
DynamicType.Builder.ExceptionDeclarableMethodInterception.throwing(TypeDescription... exceptionType)
Defines a number of
Throwable types to be include in the exception declaration. |
DynamicType.Builder.MatchedMethodInterception<S> |
DynamicType.Builder.AbstractBase.DefaultExceptionDeclarableMethodInterception.throwing(TypeDescription... exceptionType) |
| Modifier and Type | Method and Description |
|---|---|
DynamicType.Builder.ExceptionDeclarableMethodInterception<T> |
DynamicType.Builder.defineConstructor(List<? extends TypeDescription> parameterTypes,
int modifiers)
Defines a new constructor for this type.
|
DynamicType.Builder.ExceptionDeclarableMethodInterception<S> |
DynamicType.Builder.AbstractBase.defineConstructor(List<? extends TypeDescription> parameterTypes,
int modifiers) |
DynamicType.Builder.ExceptionDeclarableMethodInterception<U> |
DynamicType.Builder.AbstractBase.AbstractDelegatingBuilder.defineConstructor(List<? extends TypeDescription> parameterTypes,
int modifiers) |
DynamicType.Builder.ExceptionDeclarableMethodInterception<T> |
DynamicType.Builder.defineConstructor(List<? extends TypeDescription> parameterTypes,
ModifierContributor.ForMethod... modifier)
Defines a new constructor for this type.
|
DynamicType.Builder.ExceptionDeclarableMethodInterception<S> |
DynamicType.Builder.AbstractBase.defineConstructor(List<? extends TypeDescription> parameterTypes,
ModifierContributor.ForMethod... modifier) |
DynamicType.Builder.ExceptionDeclarableMethodInterception<U> |
DynamicType.Builder.AbstractBase.AbstractDelegatingBuilder.defineConstructor(List<? extends TypeDescription> parameterTypes,
ModifierContributor.ForMethod... modifier) |
DynamicType.Builder.ExceptionDeclarableMethodInterception<T> |
DynamicType.Builder.defineMethod(String name,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes,
int modifiers)
Defines a new method for this type.
|
DynamicType.Builder.ExceptionDeclarableMethodInterception<S> |
DynamicType.Builder.AbstractBase.defineMethod(String name,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes,
int modifiers) |
DynamicType.Builder.ExceptionDeclarableMethodInterception<U> |
DynamicType.Builder.AbstractBase.AbstractDelegatingBuilder.defineMethod(String name,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes,
int modifiers) |
DynamicType.Builder.ExceptionDeclarableMethodInterception<T> |
DynamicType.Builder.defineMethod(String name,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes,
ModifierContributor.ForMethod... modifier)
Defines a new method for this type.
|
DynamicType.Builder.ExceptionDeclarableMethodInterception<S> |
DynamicType.Builder.AbstractBase.defineMethod(String name,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes,
ModifierContributor.ForMethod... modifier) |
DynamicType.Builder.ExceptionDeclarableMethodInterception<U> |
DynamicType.Builder.AbstractBase.AbstractDelegatingBuilder.defineMethod(String name,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes,
ModifierContributor.ForMethod... modifier) |
DynamicType.Builder.OptionalMatchedMethodInterception<T> |
DynamicType.Builder.implement(Collection<? extends TypeDescription> interfaceTypes)
Adds the given interfaces to be implemented by the created type.
|
DynamicType.Builder.OptionalMatchedMethodInterception<S> |
DynamicType.Builder.AbstractBase.implement(Collection<? extends TypeDescription> interfaceTypes) |
DynamicType.Builder.OptionalMatchedMethodInterception<U> |
DynamicType.Builder.AbstractBase.AbstractDelegatingBuilder.implement(Collection<? extends TypeDescription> typeDescriptions) |
protected abstract DynamicType.Builder<S> |
DynamicType.Builder.AbstractBase.materialize(ClassFileVersion classFileVersion,
NamingStrategy namingStrategy,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
TypeDescription targetType,
List<TypeDescription> interfaceTypes,
int modifiers,
TypeAttributeAppender attributeAppender,
ElementMatcher<? super MethodDescription> ignoredMethods,
BridgeMethodResolver.Factory bridgeMethodResolverFactory,
ClassVisitorWrapper.Chain classVisitorWrapperChain,
FieldRegistry fieldRegistry,
MethodRegistry methodRegistry,
MethodLookupEngine.Factory methodLookupEngineFactory,
FieldAttributeAppender.Factory defaultFieldAttributeAppenderFactory,
MethodAttributeAppender.Factory defaultMethodAttributeAppenderFactory,
List<DynamicType.Builder.AbstractBase.FieldToken> fieldTokens,
List<DynamicType.Builder.AbstractBase.MethodToken> methodTokens)
Creates a new immutable type builder which represents the given arguments.
|
static TypeList |
TargetType.resolve(List<? extends TypeDescription> typeList,
TypeDescription actualTargetType)
Resolves any type description in the given listwith the actual target type if the
typeDescription resembles the
TargetType placeholder. |
DynamicType.Builder.MatchedMethodInterception<S> |
DynamicType.Builder.ExceptionDeclarableMethodInterception.throwing(Collection<? extends TypeDescription> exceptionTypes)
Defines a number of
Throwable types to be include in the exception declaration. |
DynamicType.Builder.MatchedMethodInterception<S> |
DynamicType.Builder.AbstractBase.DefaultExceptionDeclarableMethodInterception.throwing(Collection<? extends TypeDescription> exceptionTypes) |
| Constructor and Description |
|---|
AbstractBase(ClassFileVersion classFileVersion,
NamingStrategy namingStrategy,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
TypeDescription targetType,
List<TypeDescription> interfaceTypes,
int modifiers,
TypeAttributeAppender attributeAppender,
ElementMatcher<? super MethodDescription> ignoredMethods,
BridgeMethodResolver.Factory bridgeMethodResolverFactory,
ClassVisitorWrapper.Chain classVisitorWrapperChain,
FieldRegistry fieldRegistry,
MethodRegistry methodRegistry,
MethodLookupEngine.Factory methodLookupEngineFactory,
FieldAttributeAppender.Factory defaultFieldAttributeAppenderFactory,
MethodAttributeAppender.Factory defaultMethodAttributeAppenderFactory,
List<DynamicType.Builder.AbstractBase.FieldToken> fieldTokens,
List<DynamicType.Builder.AbstractBase.MethodToken> methodTokens)
Creates a new immutable type builder base implementation.
|
Default(TypeDescription typeDescription,
byte[] binaryRepresentation,
LoadedTypeInitializer loadedTypeInitializer,
List<? extends DynamicType> auxiliaryTypes)
Creates a new dynamic type.
|
FieldToken(String name,
TypeDescription fieldType,
int modifiers)
Creates a new field token.
|
Loaded(TypeDescription typeDescription,
byte[] typeByte,
LoadedTypeInitializer loadedTypeInitializer,
List<? extends DynamicType> auxiliaryTypes,
Map<TypeDescription,Class<?>> loadedTypes)
Creates a new representation of a loaded dynamic type.
|
MethodToken(String internalName,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes,
List<? extends TypeDescription> exceptionTypes,
int modifiers)
Creates a new method token representing a method to implement for the built dynamic type.
|
Unloaded(TypeDescription typeDescription,
byte[] typeByte,
LoadedTypeInitializer loadedTypeInitializer,
List<? extends DynamicType> auxiliaryTypes)
Creates a new unloaded representation of a dynamic type.
|
| Constructor and Description |
|---|
AbstractBase(ClassFileVersion classFileVersion,
NamingStrategy namingStrategy,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
TypeDescription targetType,
List<TypeDescription> interfaceTypes,
int modifiers,
TypeAttributeAppender attributeAppender,
ElementMatcher<? super MethodDescription> ignoredMethods,
BridgeMethodResolver.Factory bridgeMethodResolverFactory,
ClassVisitorWrapper.Chain classVisitorWrapperChain,
FieldRegistry fieldRegistry,
MethodRegistry methodRegistry,
MethodLookupEngine.Factory methodLookupEngineFactory,
FieldAttributeAppender.Factory defaultFieldAttributeAppenderFactory,
MethodAttributeAppender.Factory defaultMethodAttributeAppenderFactory,
List<DynamicType.Builder.AbstractBase.FieldToken> fieldTokens,
List<DynamicType.Builder.AbstractBase.MethodToken> methodTokens)
Creates a new immutable type builder base implementation.
|
DefaultOptionalMatchedMethodInterception(List<TypeDescription> interfaceTypes)
Creates a new subclass optional matched method interception.
|
Loaded(TypeDescription typeDescription,
byte[] typeByte,
LoadedTypeInitializer loadedTypeInitializer,
List<? extends DynamicType> auxiliaryTypes,
Map<TypeDescription,Class<?>> loadedTypes)
Creates a new representation of a loaded dynamic type.
|
MethodToken(List<? extends TypeDescription> parameterTypes,
List<? extends TypeDescription> exceptionTypes,
int modifiers)
Creates a new method token representing a constructor to implement for the built dynamic type.
|
MethodToken(List<? extends TypeDescription> parameterTypes,
List<? extends TypeDescription> exceptionTypes,
int modifiers)
Creates a new method token representing a constructor to implement for the built dynamic type.
|
MethodToken(String internalName,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes,
List<? extends TypeDescription> exceptionTypes,
int modifiers)
Creates a new method token representing a method to implement for the built dynamic type.
|
MethodToken(String internalName,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes,
List<? extends TypeDescription> exceptionTypes,
int modifiers)
Creates a new method token representing a method to implement for the built dynamic type.
|
| Modifier and Type | Method and Description |
|---|---|
Map<TypeDescription,Class<?>> |
ClassInjector.inject(Map<? extends TypeDescription,byte[]> types)
Injects the given types into the represented class loader.
|
Map<TypeDescription,Class<?>> |
ClassInjector.UsingReflection.inject(Map<? extends TypeDescription,byte[]> types) |
Map<TypeDescription,Class<?>> |
ClassInjector.UsingInstrumentation.inject(Map<? extends TypeDescription,byte[]> types) |
Map<TypeDescription,Class<?>> |
ClassReloadingStrategy.load(ClassLoader classLoader,
Map<TypeDescription,byte[]> types) |
Map<TypeDescription,Class<?>> |
ClassLoadingStrategy.load(ClassLoader classLoader,
Map<TypeDescription,byte[]> types)
Loads a given collection of classes given their binary representation.
|
Map<TypeDescription,Class<?>> |
ClassLoadingStrategy.Default.ProtectionDomainInjection.load(ClassLoader classLoader,
Map<TypeDescription,byte[]> types) |
Map<TypeDescription,Class<?>> |
ClassLoadingStrategy.Default.ProtectionDomainWrapper.load(ClassLoader classLoader,
Map<TypeDescription,byte[]> types) |
Map<TypeDescription,Class<?>> |
ClassLoadingStrategy.ForBootstrapInjection.load(ClassLoader classLoader,
Map<TypeDescription,byte[]> types) |
static Map<TypeDescription,Class<?>> |
ByteArrayClassLoader.load(ClassLoader classLoader,
Map<TypeDescription,byte[]> types,
ProtectionDomain protectionDomain,
ByteArrayClassLoader.PersistenceHandler persistenceHandler,
boolean childFirst)
Loads a given set of class descriptions and their binary representations.
|
| Modifier and Type | Method and Description |
|---|---|
Map<TypeDescription,Class<?>> |
ClassInjector.inject(Map<? extends TypeDescription,byte[]> types)
Injects the given types into the represented class loader.
|
Map<TypeDescription,Class<?>> |
ClassInjector.UsingReflection.inject(Map<? extends TypeDescription,byte[]> types) |
Map<TypeDescription,Class<?>> |
ClassInjector.UsingInstrumentation.inject(Map<? extends TypeDescription,byte[]> types) |
Map<TypeDescription,Class<?>> |
ClassReloadingStrategy.load(ClassLoader classLoader,
Map<TypeDescription,byte[]> types) |
Map<TypeDescription,Class<?>> |
ClassLoadingStrategy.load(ClassLoader classLoader,
Map<TypeDescription,byte[]> types)
Loads a given collection of classes given their binary representation.
|
Map<TypeDescription,Class<?>> |
ClassLoadingStrategy.Default.ProtectionDomainInjection.load(ClassLoader classLoader,
Map<TypeDescription,byte[]> types) |
Map<TypeDescription,Class<?>> |
ClassLoadingStrategy.Default.ProtectionDomainWrapper.load(ClassLoader classLoader,
Map<TypeDescription,byte[]> types) |
Map<TypeDescription,Class<?>> |
ClassLoadingStrategy.ForBootstrapInjection.load(ClassLoader classLoader,
Map<TypeDescription,byte[]> types) |
static Map<TypeDescription,Class<?>> |
ByteArrayClassLoader.load(ClassLoader classLoader,
Map<TypeDescription,byte[]> types,
ProtectionDomain protectionDomain,
ByteArrayClassLoader.PersistenceHandler persistenceHandler,
boolean childFirst)
Loads a given set of class descriptions and their binary representations.
|
static ClassLoader |
ByteArrayClassLoader.of(ClassLoader parent,
Map<TypeDescription,byte[]> typeDefinitions,
ProtectionDomain protectionDomain,
ByteArrayClassLoader.PersistenceHandler persistenceHandler,
boolean childFirst)
Creates a new class loader for a given definition of classes.
|
| Modifier and Type | Interface and Description |
|---|---|
interface |
InstrumentedType
Implementations of this interface represent an instrumented type that is subject to change.
|
| Modifier and Type | Class and Description |
|---|---|
static class |
InstrumentedType.AbstractBase
An abstract base implementation of an instrumented type.
|
| Modifier and Type | Field and Description |
|---|---|
protected TypeDescription |
TypeWriter.Default.instrumentedType
The instrumented type that is to be written.
|
| Modifier and Type | Method and Description |
|---|---|
TypeDescription |
InstrumentedType.detach()
Creates a compressed version of this instrumented type which only needs to fulfil the
TypeDescription interface. |
TypeDescription |
MethodLookupEngine.OverriddenClassMethod.getDeclaringType() |
TypeDescription |
MethodLookupEngine.ConflictingInterfaceMethod.getDeclaringType() |
TypeDescription |
InstrumentedType.AbstractBase.getDeclaringType() |
TypeDescription |
InstrumentedType.AbstractBase.FieldToken.getDeclaringType() |
TypeDescription |
InstrumentedType.AbstractBase.MethodToken.getDeclaringType() |
TypeDescription |
InstrumentedType.AbstractBase.getEnclosingType() |
TypeDescription |
InstrumentedType.AbstractBase.FieldToken.getFieldType() |
TypeDescription |
MethodRegistry.Prepared.getInstrumentedType()
Returns the fully prepared instrumented type.
|
TypeDescription |
MethodRegistry.Compiled.getInstrumentedType()
Returns the instrumented type that is to be created.
|
TypeDescription |
MethodRegistry.Default.Prepared.getInstrumentedType() |
TypeDescription |
MethodRegistry.Default.Compiled.getInstrumentedType() |
TypeDescription |
MethodLookupEngine.OverriddenClassMethod.getReturnType() |
TypeDescription |
MethodLookupEngine.ConflictingInterfaceMethod.getReturnType() |
TypeDescription |
InstrumentedType.AbstractBase.MethodToken.getReturnType() |
TypeDescription |
MethodLookupEngine.Finding.getTypeDescription()
Returns the type description for which the finding was created.
|
TypeDescription |
MethodLookupEngine.Finding.Default.getTypeDescription() |
TypeDescription |
InstrumentedType.AbstractBase.MethodToken.ParameterToken.getTypeDescription() |
| Modifier and Type | Method and Description |
|---|---|
protected abstract Map<TypeDescription,Set<MethodDescription>> |
MethodLookupEngine.Default.apply(MethodLookupEngine.Default.MethodBucket methodBucket,
Collection<TypeDescription> interfaces,
Collection<TypeDescription> defaultMethodRelevantInterfaces)
Applies default method extraction.
|
Map<TypeDescription,Set<MethodDescription>> |
MethodLookupEngine.Finding.getInvokableDefaultMethods()
Returns a map of interfaces that are eligible for default method invocation on the type this finding
was created for.
|
Map<TypeDescription,Set<MethodDescription>> |
MethodLookupEngine.Finding.Default.getInvokableDefaultMethods() |
protected Map<TypeDescription,Set<MethodDescription>> |
MethodLookupEngine.Default.MethodBucket.DefaultMethodLookup.Enabled.materialize()
Returns a map of all default method interfaces that were extracted by this default method lookup.
|
| Modifier and Type | Method and Description |
|---|---|
void |
MethodLookupEngine.Default.MethodBucket.DefaultMethodLookup.begin(TypeDescription typeDescription)
Announces the begin of the analysis of a given type.
|
void |
MethodLookupEngine.Default.MethodBucket.DefaultMethodLookup.Disabled.begin(TypeDescription typeDescription) |
void |
MethodLookupEngine.Default.MethodBucket.DefaultMethodLookup.Enabled.begin(TypeDescription typeDescription) |
void |
MethodLookupEngine.Default.MethodBucket.DefaultMethodLookup.complete(TypeDescription typeDescription)
Announces that a type was fully analyzed, including all of its super interfaces.
|
void |
MethodLookupEngine.Default.MethodBucket.DefaultMethodLookup.Disabled.complete(TypeDescription typeDescription) |
void |
MethodLookupEngine.Default.MethodBucket.DefaultMethodLookup.Enabled.complete(TypeDescription typeDescription) |
static <U> TypeWriter<U> |
TypeWriter.Default.forRebasing(MethodRegistry.Compiled methodRegistry,
TypeWriter.FieldPool fieldPool,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
ClassVisitorWrapper classVisitorWrapper,
TypeAttributeAppender attributeAppender,
ClassFileVersion classFileVersion,
ClassFileLocator classFileLocator,
TypeDescription targetType,
MethodRebaseResolver methodRebaseResolver)
Creates a type writer for creating a new type.
|
static <U> TypeWriter<U> |
TypeWriter.Default.forRedefinition(MethodRegistry.Compiled methodRegistry,
TypeWriter.FieldPool fieldPool,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
ClassVisitorWrapper classVisitorWrapper,
TypeAttributeAppender attributeAppender,
ClassFileVersion classFileVersion,
ClassFileLocator classFileLocator,
TypeDescription targetType)
Creates a type writer for creating a new type.
|
boolean |
MethodLookupEngine.OverriddenClassMethod.isSpecializableFor(TypeDescription targetType) |
boolean |
MethodLookupEngine.ConflictingInterfaceMethod.isSpecializableFor(TypeDescription targetType) |
protected static MethodDescription |
MethodLookupEngine.ConflictingInterfaceMethod.of(TypeDescription virtualHost,
MethodDescription conflictingMethod,
MethodDescription discoveredMethod)
Creates a new method description for at least two conflicting interface methods.
|
FieldRegistry.Prepared |
FieldRegistry.prepare(TypeDescription instrumentedType)
Prepares the field registry for a given instrumented type.
|
FieldRegistry.Prepared |
FieldRegistry.Default.prepare(TypeDescription instrumentedType) |
MethodLookupEngine.Finding |
MethodLookupEngine.process(TypeDescription typeDescription)
Retrieves all methods that can be called on a given type.
|
MethodLookupEngine.Finding |
MethodLookupEngine.Default.process(TypeDescription typeDescription) |
ElementMatcher<? super MethodDescription> |
MethodRegistry.Default.Entry.resolve(TypeDescription instrumentedType) |
InstrumentedType |
InstrumentedType.withField(String internalName,
TypeDescription fieldType,
int modifiers)
Creates a new instrumented type that includes a new field.
|
InstrumentedType |
InstrumentedType.withMethod(String internalName,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes,
List<? extends TypeDescription> exceptionTypes,
int modifiers)
Creates a new instrumented type that includes a new method or constructor.
|
| Modifier and Type | Method and Description |
|---|---|
protected abstract Map<TypeDescription,Set<MethodDescription>> |
MethodLookupEngine.Default.apply(MethodLookupEngine.Default.MethodBucket methodBucket,
Collection<TypeDescription> interfaces,
Collection<TypeDescription> defaultMethodRelevantInterfaces)
Applies default method extraction.
|
protected abstract Map<TypeDescription,Set<MethodDescription>> |
MethodLookupEngine.Default.apply(MethodLookupEngine.Default.MethodBucket methodBucket,
Collection<TypeDescription> interfaces,
Collection<TypeDescription> defaultMethodRelevantInterfaces)
Applies default method extraction.
|
InstrumentedType |
InstrumentedType.withMethod(String internalName,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes,
List<? extends TypeDescription> exceptionTypes,
int modifiers)
Creates a new instrumented type that includes a new method or constructor.
|
InstrumentedType |
InstrumentedType.withMethod(String internalName,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes,
List<? extends TypeDescription> exceptionTypes,
int modifiers)
Creates a new instrumented type that includes a new method or constructor.
|
| Constructor and Description |
|---|
Compiled(TypeDescription instrumentedType,
LoadedTypeInitializer loadedTypeInitializer,
InstrumentedType.TypeInitializer typeInitializer,
Map<MethodDescription,TypeWriter.MethodPool.Entry> implementations)
Creates a new compiled version of a default method registry.
|
ConflictingInterfaceMethod(TypeDescription virtualHost,
List<MethodDescription> methodDescriptions)
Creates a new conflicting interface method.
|
Default(TypeDescription instrumentedType,
LoadedTypeInitializer loadedTypeInitializer,
InstrumentedType.TypeInitializer typeInitializer,
List<DynamicType> explicitAuxiliaryTypes,
ClassFileVersion classFileVersion,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
ClassVisitorWrapper classVisitorWrapper,
TypeAttributeAppender attributeAppender,
TypeWriter.FieldPool fieldPool,
TypeWriter.MethodPool methodPool,
MethodList instrumentedMethods)
Creates a new default type writer.
|
Default(TypeDescription lookedUpType,
MethodList invokableMethods,
Map<TypeDescription,Set<MethodDescription>> invokableDefaultMethods)
Creates a default of a
MethodLookupEngine.Finding. |
ForCreation(TypeDescription instrumentedType,
LoadedTypeInitializer loadedTypeInitializer,
InstrumentedType.TypeInitializer typeInitializer,
List<DynamicType> explicitAuxiliaryTypes,
ClassFileVersion classFileVersion,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
ClassVisitorWrapper classVisitorWrapper,
TypeAttributeAppender attributeAppender,
TypeWriter.FieldPool fieldPool,
TypeWriter.MethodPool methodPool,
MethodList instrumentedMethods)
Creates a new type writer for creating a new type.
|
ForInlining(TypeDescription instrumentedType,
LoadedTypeInitializer loadedTypeInitializer,
InstrumentedType.TypeInitializer typeInitializer,
List<DynamicType> explicitAuxiliaryTypes,
ClassFileVersion classFileVersion,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
ClassVisitorWrapper classVisitorWrapper,
TypeAttributeAppender attributeAppender,
TypeWriter.FieldPool fieldPool,
TypeWriter.MethodPool methodPool,
MethodList instrumentedMethods,
ClassFileLocator classFileLocator,
TypeDescription targetType,
MethodRebaseResolver methodRebaseResolver)
Creates a new type writer for inling a type into an existing type description.
|
MethodBucket(TypeDescription typeOfInterest)
Creates a new mutable method bucket.
|
| Constructor and Description |
|---|
Default(TypeDescription lookedUpType,
MethodList invokableMethods,
Map<TypeDescription,Set<MethodDescription>> invokableDefaultMethods)
Creates a default of a
MethodLookupEngine.Finding. |
Enabled(Collection<? extends TypeDescription> declaredInterfaceTypes)
Creates a new mutable canonical implementation of a default method lookup.
|
| Modifier and Type | Class and Description |
|---|---|
class |
InlineInstrumentedType
An instrumented type which enhances a given type description by an extending redefinition.
|
| Modifier and Type | Method and Description |
|---|---|
TypeDescription |
InlineInstrumentedType.detach() |
TypeDescription |
RebaseImplementationTarget.getOriginType() |
TypeDescription |
InlineInstrumentedType.getSupertype() |
TypeDescription |
RebaseImplementationTarget.RebasedMethodSpecialMethodInvocation.getTypeDescription() |
| Modifier and Type | Method and Description |
|---|---|
static MethodRebaseResolver |
MethodRebaseResolver.Enabled.make(MethodList instrumentedMethods,
TypeDescription instrumentedType,
ClassFileVersion classFileVersion,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
MethodRebaseResolver.MethodNameTransformer methodNameTransformer)
Creates a method rebase resolver which is only capable of rebasing constructors if the instrumented methods suggest this.
|
protected DynamicType.Builder<T> |
RedefinitionDynamicTypeBuilder.materialize(ClassFileVersion classFileVersion,
NamingStrategy namingStrategy,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
TypeDescription levelType,
List<TypeDescription> interfaceTypes,
int modifiers,
TypeAttributeAppender attributeAppender,
ElementMatcher<? super MethodDescription> ignoredMethods,
BridgeMethodResolver.Factory bridgeMethodResolverFactory,
ClassVisitorWrapper.Chain classVisitorWrapperChain,
FieldRegistry fieldRegistry,
MethodRegistry methodRegistry,
MethodLookupEngine.Factory methodLookupEngineFactory,
FieldAttributeAppender.Factory defaultFieldAttributeAppenderFactory,
MethodAttributeAppender.Factory defaultMethodAttributeAppenderFactory,
List<DynamicType.Builder.AbstractBase.FieldToken> fieldTokens,
List<DynamicType.Builder.AbstractBase.MethodToken> methodTokens) |
protected DynamicType.Builder<T> |
RebaseDynamicTypeBuilder.materialize(ClassFileVersion classFileVersion,
NamingStrategy namingStrategy,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
TypeDescription levelType,
List<TypeDescription> interfaceTypes,
int modifiers,
TypeAttributeAppender attributeAppender,
ElementMatcher<? super MethodDescription> ignoredMethods,
BridgeMethodResolver.Factory bridgeMethodResolverFactory,
ClassVisitorWrapper.Chain classVisitorWrapperChain,
FieldRegistry fieldRegistry,
MethodRegistry methodRegistry,
MethodLookupEngine.Factory methodLookupEngineFactory,
FieldAttributeAppender.Factory defaultFieldAttributeAppenderFactory,
MethodAttributeAppender.Factory defaultMethodAttributeAppenderFactory,
List<DynamicType.Builder.AbstractBase.FieldToken> fieldTokens,
List<DynamicType.Builder.AbstractBase.MethodToken> methodTokens) |
protected static LatentMethodMatcher |
InliningImplementationMatcher.of(ElementMatcher<? super MethodDescription> ignoredMethods,
TypeDescription targetType)
Creates a matcher where only overridable or declared methods are matched unless those are ignored.
|
static Implementation.SpecialMethodInvocation |
RebaseImplementationTarget.RebasedMethodSpecialMethodInvocation.of(MethodRebaseResolver.Resolution resolution,
TypeDescription instrumentedType)
Creates a special method invocation for a rebased method if such an invocation is possible or otherwise
returns an illegal special method invocation.
|
ElementMatcher<? super MethodDescription> |
InliningImplementationMatcher.resolve(TypeDescription instrumentedType) |
InstrumentedType |
InlineInstrumentedType.withField(String internalName,
TypeDescription fieldType,
int modifiers) |
InstrumentedType |
InlineInstrumentedType.withMethod(String internalName,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes,
List<? extends TypeDescription> exceptionTypes,
int modifiers) |
| Modifier and Type | Method and Description |
|---|---|
protected DynamicType.Builder<T> |
RedefinitionDynamicTypeBuilder.materialize(ClassFileVersion classFileVersion,
NamingStrategy namingStrategy,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
TypeDescription levelType,
List<TypeDescription> interfaceTypes,
int modifiers,
TypeAttributeAppender attributeAppender,
ElementMatcher<? super MethodDescription> ignoredMethods,
BridgeMethodResolver.Factory bridgeMethodResolverFactory,
ClassVisitorWrapper.Chain classVisitorWrapperChain,
FieldRegistry fieldRegistry,
MethodRegistry methodRegistry,
MethodLookupEngine.Factory methodLookupEngineFactory,
FieldAttributeAppender.Factory defaultFieldAttributeAppenderFactory,
MethodAttributeAppender.Factory defaultMethodAttributeAppenderFactory,
List<DynamicType.Builder.AbstractBase.FieldToken> fieldTokens,
List<DynamicType.Builder.AbstractBase.MethodToken> methodTokens) |
protected DynamicType.Builder<T> |
RebaseDynamicTypeBuilder.materialize(ClassFileVersion classFileVersion,
NamingStrategy namingStrategy,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
TypeDescription levelType,
List<TypeDescription> interfaceTypes,
int modifiers,
TypeAttributeAppender attributeAppender,
ElementMatcher<? super MethodDescription> ignoredMethods,
BridgeMethodResolver.Factory bridgeMethodResolverFactory,
ClassVisitorWrapper.Chain classVisitorWrapperChain,
FieldRegistry fieldRegistry,
MethodRegistry methodRegistry,
MethodLookupEngine.Factory methodLookupEngineFactory,
FieldAttributeAppender.Factory defaultFieldAttributeAppenderFactory,
MethodAttributeAppender.Factory defaultMethodAttributeAppenderFactory,
List<DynamicType.Builder.AbstractBase.FieldToken> fieldTokens,
List<DynamicType.Builder.AbstractBase.MethodToken> methodTokens) |
InstrumentedType |
InlineInstrumentedType.withMethod(String internalName,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes,
List<? extends TypeDescription> exceptionTypes,
int modifiers) |
InstrumentedType |
InlineInstrumentedType.withMethod(String internalName,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes,
List<? extends TypeDescription> exceptionTypes,
int modifiers) |
| Constructor and Description |
|---|
ForRebasedConstructor(MethodDescription methodDescription,
TypeDescription placeholderType)
Creates a
MethodRebaseResolver.Resolution for a
rebased method. |
InlineInstrumentedType(ClassFileVersion classFileVersion,
TypeDescription levelType,
List<TypeDescription> interfaces,
int modifiers,
NamingStrategy namingStrategy)
Creates a new inlined instrumented type.
|
InlineInstrumentedType(TypeDescription levelType,
String name,
List<TypeDescription> interfaces,
int modifiers,
List<? extends FieldDescription> fieldDescriptions,
List<? extends MethodDescription> methodDescriptions,
LoadedTypeInitializer loadedTypeInitializer,
InstrumentedType.TypeInitializer typeInitializer)
Creates a new inlined instrumented type.
|
RebasedMethodSpecialMethodInvocation(MethodRebaseResolver.Resolution resolution,
TypeDescription instrumentedType)
Creates a special method invocation for a rebased method.
|
RebaseDynamicTypeBuilder(ClassFileVersion classFileVersion,
NamingStrategy namingStrategy,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
TypeDescription levelType,
List<? extends TypeDescription> interfaceTypes,
int modifiers,
TypeAttributeAppender attributeAppender,
ElementMatcher<? super MethodDescription> ignoredMethods,
BridgeMethodResolver.Factory bridgeMethodResolverFactory,
ClassVisitorWrapper.Chain classVisitorWrapperChain,
FieldRegistry fieldRegistry,
MethodRegistry methodRegistry,
MethodLookupEngine.Factory methodLookupEngineFactory,
FieldAttributeAppender.Factory defaultFieldAttributeAppenderFactory,
MethodAttributeAppender.Factory defaultMethodAttributeAppenderFactory,
ClassFileLocator classFileLocator,
MethodRebaseResolver.MethodNameTransformer methodNameTransformer)
Creates a new rebase dynamic type builder.
|
RebaseDynamicTypeBuilder(ClassFileVersion classFileVersion,
NamingStrategy namingStrategy,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
TypeDescription levelType,
List<TypeDescription> interfaceTypes,
int modifiers,
TypeAttributeAppender attributeAppender,
ElementMatcher<? super MethodDescription> ignoredMethods,
BridgeMethodResolver.Factory bridgeMethodResolverFactory,
ClassVisitorWrapper.Chain classVisitorWrapperChain,
FieldRegistry fieldRegistry,
MethodRegistry methodRegistry,
MethodLookupEngine.Factory methodLookupEngineFactory,
FieldAttributeAppender.Factory defaultFieldAttributeAppenderFactory,
MethodAttributeAppender.Factory defaultMethodAttributeAppenderFactory,
List<DynamicType.Builder.AbstractBase.FieldToken> fieldTokens,
List<DynamicType.Builder.AbstractBase.MethodToken> methodTokens,
ClassFileLocator classFileLocator,
MethodRebaseResolver.MethodNameTransformer methodNameTransformer)
Creates a new rebase dynamic type builder.
|
RedefinitionDynamicTypeBuilder(ClassFileVersion classFileVersion,
NamingStrategy namingStrategy,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
TypeDescription levelType,
List<? extends TypeDescription> interfaceTypes,
int modifiers,
TypeAttributeAppender attributeAppender,
ElementMatcher<? super MethodDescription> ignoredMethods,
BridgeMethodResolver.Factory bridgeMethodResolverFactory,
ClassVisitorWrapper.Chain classVisitorWrapperChain,
FieldRegistry fieldRegistry,
MethodRegistry methodRegistry,
MethodLookupEngine.Factory methodLookupEngineFactory,
FieldAttributeAppender.Factory defaultFieldAttributeAppenderFactory,
MethodAttributeAppender.Factory defaultMethodAttributeAppenderFactory,
ClassFileLocator classFileLocator)
Creates a new redefinition dynamic type builder.
|
RedefinitionDynamicTypeBuilder(ClassFileVersion classFileVersion,
NamingStrategy namingStrategy,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
TypeDescription levelType,
List<? extends TypeDescription> interfaceTypes,
int modifiers,
TypeAttributeAppender attributeAppender,
ElementMatcher<? super MethodDescription> ignoredMethods,
BridgeMethodResolver.Factory bridgeMethodResolverFactory,
ClassVisitorWrapper.Chain classVisitorWrapperChain,
FieldRegistry fieldRegistry,
MethodRegistry methodRegistry,
MethodLookupEngine.Factory methodLookupEngineFactory,
FieldAttributeAppender.Factory defaultFieldAttributeAppenderFactory,
MethodAttributeAppender.Factory defaultMethodAttributeAppenderFactory,
List<DynamicType.Builder.AbstractBase.FieldToken> fieldTokens,
List<DynamicType.Builder.AbstractBase.MethodToken> methodTokens,
ClassFileLocator classFileLocator)
Creates a new redefinition dynamic type builder.
|
| Constructor and Description |
|---|
InlineInstrumentedType(ClassFileVersion classFileVersion,
TypeDescription levelType,
List<TypeDescription> interfaces,
int modifiers,
NamingStrategy namingStrategy)
Creates a new inlined instrumented type.
|
InlineInstrumentedType(TypeDescription levelType,
String name,
List<TypeDescription> interfaces,
int modifiers,
List<? extends FieldDescription> fieldDescriptions,
List<? extends MethodDescription> methodDescriptions,
LoadedTypeInitializer loadedTypeInitializer,
InstrumentedType.TypeInitializer typeInitializer)
Creates a new inlined instrumented type.
|
RebaseDynamicTypeBuilder(ClassFileVersion classFileVersion,
NamingStrategy namingStrategy,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
TypeDescription levelType,
List<? extends TypeDescription> interfaceTypes,
int modifiers,
TypeAttributeAppender attributeAppender,
ElementMatcher<? super MethodDescription> ignoredMethods,
BridgeMethodResolver.Factory bridgeMethodResolverFactory,
ClassVisitorWrapper.Chain classVisitorWrapperChain,
FieldRegistry fieldRegistry,
MethodRegistry methodRegistry,
MethodLookupEngine.Factory methodLookupEngineFactory,
FieldAttributeAppender.Factory defaultFieldAttributeAppenderFactory,
MethodAttributeAppender.Factory defaultMethodAttributeAppenderFactory,
ClassFileLocator classFileLocator,
MethodRebaseResolver.MethodNameTransformer methodNameTransformer)
Creates a new rebase dynamic type builder.
|
RebaseDynamicTypeBuilder(ClassFileVersion classFileVersion,
NamingStrategy namingStrategy,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
TypeDescription levelType,
List<TypeDescription> interfaceTypes,
int modifiers,
TypeAttributeAppender attributeAppender,
ElementMatcher<? super MethodDescription> ignoredMethods,
BridgeMethodResolver.Factory bridgeMethodResolverFactory,
ClassVisitorWrapper.Chain classVisitorWrapperChain,
FieldRegistry fieldRegistry,
MethodRegistry methodRegistry,
MethodLookupEngine.Factory methodLookupEngineFactory,
FieldAttributeAppender.Factory defaultFieldAttributeAppenderFactory,
MethodAttributeAppender.Factory defaultMethodAttributeAppenderFactory,
List<DynamicType.Builder.AbstractBase.FieldToken> fieldTokens,
List<DynamicType.Builder.AbstractBase.MethodToken> methodTokens,
ClassFileLocator classFileLocator,
MethodRebaseResolver.MethodNameTransformer methodNameTransformer)
Creates a new rebase dynamic type builder.
|
RedefinitionDynamicTypeBuilder(ClassFileVersion classFileVersion,
NamingStrategy namingStrategy,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
TypeDescription levelType,
List<? extends TypeDescription> interfaceTypes,
int modifiers,
TypeAttributeAppender attributeAppender,
ElementMatcher<? super MethodDescription> ignoredMethods,
BridgeMethodResolver.Factory bridgeMethodResolverFactory,
ClassVisitorWrapper.Chain classVisitorWrapperChain,
FieldRegistry fieldRegistry,
MethodRegistry methodRegistry,
MethodLookupEngine.Factory methodLookupEngineFactory,
FieldAttributeAppender.Factory defaultFieldAttributeAppenderFactory,
MethodAttributeAppender.Factory defaultMethodAttributeAppenderFactory,
ClassFileLocator classFileLocator)
Creates a new redefinition dynamic type builder.
|
RedefinitionDynamicTypeBuilder(ClassFileVersion classFileVersion,
NamingStrategy namingStrategy,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
TypeDescription levelType,
List<? extends TypeDescription> interfaceTypes,
int modifiers,
TypeAttributeAppender attributeAppender,
ElementMatcher<? super MethodDescription> ignoredMethods,
BridgeMethodResolver.Factory bridgeMethodResolverFactory,
ClassVisitorWrapper.Chain classVisitorWrapperChain,
FieldRegistry fieldRegistry,
MethodRegistry methodRegistry,
MethodLookupEngine.Factory methodLookupEngineFactory,
FieldAttributeAppender.Factory defaultFieldAttributeAppenderFactory,
MethodAttributeAppender.Factory defaultMethodAttributeAppenderFactory,
List<DynamicType.Builder.AbstractBase.FieldToken> fieldTokens,
List<DynamicType.Builder.AbstractBase.MethodToken> methodTokens,
ClassFileLocator classFileLocator)
Creates a new redefinition dynamic type builder.
|
| Modifier and Type | Class and Description |
|---|---|
class |
SubclassInstrumentedType
Represents a type instrumentation that creates a new type based on a given superclass.
|
| Modifier and Type | Method and Description |
|---|---|
TypeDescription |
SubclassInstrumentedType.detach() |
TypeDescription |
SubclassImplementationTarget.getOriginType() |
TypeDescription |
SubclassInstrumentedType.getSupertype() |
protected abstract TypeDescription |
SubclassImplementationTarget.OriginTypeIdentifier.identify(TypeDescription typeDescription)
Identifies the origin type to a given type description.
|
| Modifier and Type | Method and Description |
|---|---|
MethodList |
ConstructorStrategy.extractConstructors(TypeDescription instrumentedType)
Extracts constructors for a given super type.
|
protected abstract TypeDescription |
SubclassImplementationTarget.OriginTypeIdentifier.identify(TypeDescription typeDescription)
Identifies the origin type to a given type description.
|
protected DynamicType.Builder<T> |
SubclassDynamicTypeBuilder.materialize(ClassFileVersion classFileVersion,
NamingStrategy namingStrategy,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
TypeDescription targetType,
List<TypeDescription> interfaceTypes,
int modifiers,
TypeAttributeAppender attributeAppender,
ElementMatcher<? super MethodDescription> ignoredMethods,
BridgeMethodResolver.Factory bridgeMethodResolverFactory,
ClassVisitorWrapper.Chain classVisitorWrapperChain,
FieldRegistry fieldRegistry,
MethodRegistry methodRegistry,
MethodLookupEngine.Factory methodLookupEngineFactory,
FieldAttributeAppender.Factory defaultFieldAttributeAppenderFactory,
MethodAttributeAppender.Factory defaultMethodAttributeAppenderFactory,
List<DynamicType.Builder.AbstractBase.FieldToken> fieldTokens,
List<DynamicType.Builder.AbstractBase.MethodToken> methodTokens) |
ElementMatcher<? super MethodDescription> |
SubclassDynamicTypeBuilder.InstrumentableMatcher.resolve(TypeDescription instrumentedType) |
InstrumentedType |
SubclassInstrumentedType.withField(String internalName,
TypeDescription fieldType,
int modifiers) |
InstrumentedType |
SubclassInstrumentedType.withMethod(String internalName,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes,
List<? extends TypeDescription> exceptionTypes,
int modifiers) |
| Modifier and Type | Method and Description |
|---|---|
protected DynamicType.Builder<T> |
SubclassDynamicTypeBuilder.materialize(ClassFileVersion classFileVersion,
NamingStrategy namingStrategy,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
TypeDescription targetType,
List<TypeDescription> interfaceTypes,
int modifiers,
TypeAttributeAppender attributeAppender,
ElementMatcher<? super MethodDescription> ignoredMethods,
BridgeMethodResolver.Factory bridgeMethodResolverFactory,
ClassVisitorWrapper.Chain classVisitorWrapperChain,
FieldRegistry fieldRegistry,
MethodRegistry methodRegistry,
MethodLookupEngine.Factory methodLookupEngineFactory,
FieldAttributeAppender.Factory defaultFieldAttributeAppenderFactory,
MethodAttributeAppender.Factory defaultMethodAttributeAppenderFactory,
List<DynamicType.Builder.AbstractBase.FieldToken> fieldTokens,
List<DynamicType.Builder.AbstractBase.MethodToken> methodTokens) |
InstrumentedType |
SubclassInstrumentedType.withMethod(String internalName,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes,
List<? extends TypeDescription> exceptionTypes,
int modifiers) |
InstrumentedType |
SubclassInstrumentedType.withMethod(String internalName,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes,
List<? extends TypeDescription> exceptionTypes,
int modifiers) |
| Constructor and Description |
|---|
SubclassDynamicTypeBuilder(ClassFileVersion classFileVersion,
NamingStrategy namingStrategy,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
TypeDescription superType,
List<? extends TypeDescription> interfaceTypes,
int modifiers,
TypeAttributeAppender attributeAppender,
ElementMatcher<? super MethodDescription> ignoredMethods,
BridgeMethodResolver.Factory bridgeMethodResolverFactory,
ClassVisitorWrapper.Chain classVisitorWrapperChain,
FieldRegistry fieldRegistry,
MethodRegistry methodRegistry,
MethodLookupEngine.Factory methodLookupEngineFactory,
FieldAttributeAppender.Factory defaultFieldAttributeAppenderFactory,
MethodAttributeAppender.Factory defaultMethodAttributeAppenderFactory,
ConstructorStrategy constructorStrategy)
Creates a new immutable type builder for a subclassing a given class.
|
SubclassDynamicTypeBuilder(ClassFileVersion classFileVersion,
NamingStrategy namingStrategy,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
TypeDescription superType,
List<TypeDescription> interfaceTypes,
int modifiers,
TypeAttributeAppender attributeAppender,
ElementMatcher<? super MethodDescription> ignoredMethods,
BridgeMethodResolver.Factory bridgeMethodResolverFactory,
ClassVisitorWrapper.Chain classVisitorWrapperChain,
FieldRegistry fieldRegistry,
MethodRegistry methodRegistry,
MethodLookupEngine.Factory methodLookupEngineFactory,
FieldAttributeAppender.Factory defaultFieldAttributeAppenderFactory,
MethodAttributeAppender.Factory defaultMethodAttributeAppenderFactory,
List<DynamicType.Builder.AbstractBase.FieldToken> fieldTokens,
List<DynamicType.Builder.AbstractBase.MethodToken> methodTokens,
ConstructorStrategy constructorStrategy)
Creates a new immutable type builder for a subclassing a given class.
|
SubclassInstrumentedType(ClassFileVersion classFileVersion,
TypeDescription superClass,
List<TypeDescription> interfaces,
int modifiers,
NamingStrategy namingStrategy)
Creates a new immutable type instrumentation for a loaded superclass.
|
SubclassInstrumentedType(ClassFileVersion classFileVersion,
TypeDescription superClass,
List<TypeDescription> interfaces,
int modifiers,
String name,
List<? extends FieldDescription> fieldDescriptions,
List<? extends MethodDescription> methodDescriptions,
LoadedTypeInitializer loadedTypeInitializer,
InstrumentedType.TypeInitializer typeInitializer)
Creates a new immutable type instrumentation for a loaded superclass.
|
| Constructor and Description |
|---|
SubclassDynamicTypeBuilder(ClassFileVersion classFileVersion,
NamingStrategy namingStrategy,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
TypeDescription superType,
List<? extends TypeDescription> interfaceTypes,
int modifiers,
TypeAttributeAppender attributeAppender,
ElementMatcher<? super MethodDescription> ignoredMethods,
BridgeMethodResolver.Factory bridgeMethodResolverFactory,
ClassVisitorWrapper.Chain classVisitorWrapperChain,
FieldRegistry fieldRegistry,
MethodRegistry methodRegistry,
MethodLookupEngine.Factory methodLookupEngineFactory,
FieldAttributeAppender.Factory defaultFieldAttributeAppenderFactory,
MethodAttributeAppender.Factory defaultMethodAttributeAppenderFactory,
ConstructorStrategy constructorStrategy)
Creates a new immutable type builder for a subclassing a given class.
|
SubclassDynamicTypeBuilder(ClassFileVersion classFileVersion,
NamingStrategy namingStrategy,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
TypeDescription superType,
List<TypeDescription> interfaceTypes,
int modifiers,
TypeAttributeAppender attributeAppender,
ElementMatcher<? super MethodDescription> ignoredMethods,
BridgeMethodResolver.Factory bridgeMethodResolverFactory,
ClassVisitorWrapper.Chain classVisitorWrapperChain,
FieldRegistry fieldRegistry,
MethodRegistry methodRegistry,
MethodLookupEngine.Factory methodLookupEngineFactory,
FieldAttributeAppender.Factory defaultFieldAttributeAppenderFactory,
MethodAttributeAppender.Factory defaultMethodAttributeAppenderFactory,
List<DynamicType.Builder.AbstractBase.FieldToken> fieldTokens,
List<DynamicType.Builder.AbstractBase.MethodToken> methodTokens,
ConstructorStrategy constructorStrategy)
Creates a new immutable type builder for a subclassing a given class.
|
SubclassInstrumentedType(ClassFileVersion classFileVersion,
TypeDescription superClass,
List<TypeDescription> interfaces,
int modifiers,
NamingStrategy namingStrategy)
Creates a new immutable type instrumentation for a loaded superclass.
|
SubclassInstrumentedType(ClassFileVersion classFileVersion,
TypeDescription superClass,
List<TypeDescription> interfaces,
int modifiers,
String name,
List<? extends FieldDescription> fieldDescriptions,
List<? extends MethodDescription> methodDescriptions,
LoadedTypeInitializer loadedTypeInitializer,
InstrumentedType.TypeInitializer typeInitializer)
Creates a new immutable type instrumentation for a loaded superclass.
|
| Modifier and Type | Field and Description |
|---|---|
protected TypeDescription |
Forwarding.fieldType
The type of the field.
|
protected TypeDescription |
Implementation.Target.AbstractBase.typeDescription
The type that is subject to instrumentation.
|
| Modifier and Type | Field and Description |
|---|---|
protected Map<TypeDescription,Map<String,MethodDescription>> |
Implementation.Target.AbstractBase.defaultMethods
A map of default methods by their unique signature.
|
| Modifier and Type | Method and Description |
|---|---|
TypeDescription |
Implementation.Context.Default.FieldCacheEntry.getFieldType()
Returns the field type that is represented by this field cache entry.
|
TypeDescription |
Implementation.Target.getOriginType()
Identifies the origin type of an implementation.
|
TypeDescription |
InvokeDynamic.InvocationProvider.Target.Resolved.getReturnType()
Returns the requested return type.
|
TypeDescription |
InvokeDynamic.InvocationProvider.Target.Resolved.Simple.getReturnType() |
TypeDescription |
InvokeDynamic.InvocationProvider.Target.ForMethodDescription.getReturnType() |
TypeDescription |
Implementation.SpecialMethodInvocation.getTypeDescription()
Returns the target type the represented method is invoked on.
|
TypeDescription |
Implementation.SpecialMethodInvocation.Illegal.getTypeDescription() |
TypeDescription |
Implementation.SpecialMethodInvocation.Simple.getTypeDescription() |
TypeDescription |
Implementation.Target.getTypeDescription()
Returns a description of the instrumented type.
|
TypeDescription |
Implementation.Target.AbstractBase.getTypeDescription() |
TypeDescription |
Implementation.Context.register(AuxiliaryType auxiliaryType)
Registers an auxiliary type as required for the current implementation.
|
TypeDescription |
Implementation.Context.Default.register(AuxiliaryType auxiliaryType) |
TypeDescription |
InvokeDynamic.InvocationProvider.ReturnTypeProvider.resolve(MethodDescription methodDescription)
Resolves the return type that is requested from the bootstrap method.
|
TypeDescription |
InvokeDynamic.InvocationProvider.ReturnTypeProvider.ForInterceptedMethod.resolve(MethodDescription methodDescription) |
TypeDescription |
InvokeDynamic.InvocationProvider.ReturnTypeProvider.ForExplicitType.resolve(MethodDescription methodDescription) |
| Modifier and Type | Method and Description |
|---|---|
List<TypeDescription> |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved.getLoadedTypes()
Returns a list of all types of the arguments that were loaded onto the operand stack.
|
List<TypeDescription> |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved.Simple.getLoadedTypes() |
List<TypeDescription> |
InvokeDynamic.InvocationProvider.Target.Resolved.getParameterTypes()
Returns the types of the values on the operand stack.
|
List<TypeDescription> |
InvokeDynamic.InvocationProvider.Target.Resolved.Simple.getParameterTypes() |
List<TypeDescription> |
InvokeDynamic.InvocationProvider.Target.ForMethodDescription.getParameterTypes() |
| Modifier and Type | Method and Description |
|---|---|
protected ByteCodeAppender.Size |
InvocationHandlerAdapter.apply(MethodVisitor methodVisitor,
Implementation.Context implementationContext,
MethodDescription instrumentedMethod,
TypeDescription instrumentedType,
StackManipulation preparingManipulation)
Applies an implementation that delegates to a invocation handler.
|
protected ByteCodeAppender.Size |
FixedValue.apply(MethodVisitor methodVisitor,
Implementation.Context implementationContext,
MethodDescription instrumentedMethod,
TypeDescription fixedValueType,
StackManipulation valueLoadingInstruction)
Blueprint method that for applying the actual implementation.
|
InvokeDynamic |
InvokeDynamic.WithImplicitFieldType.as(TypeDescription typeDescription)
Defines the given value to be treated as an instance of the provided type.
|
InvokeDynamic |
InvokeDynamic.WithImplicitArgumentType.as(TypeDescription typeDescription)
Defines the given argument to be treated as an instance of the provided type.
|
FieldDescription |
Implementation.Context.cache(StackManipulation fieldValue,
TypeDescription fieldType)
Caches a single value by storing it in form of a
private, final and static field. |
FieldDescription |
Implementation.Context.Default.cache(StackManipulation fieldValue,
TypeDescription fieldType) |
FieldAccessor.AssignerConfigurable |
FieldAccessor.FieldDefinable.defineAs(TypeDescription typeDescription,
ModifierContributor.ForField... modifier)
Defines a field with the given name in the instrumented type.
|
FieldAccessor.AssignerConfigurable |
FieldAccessor.ForNamedField.defineAs(TypeDescription typeDescription,
ModifierContributor.ForField... modifier) |
MethodDelegationBinder.MethodInvoker |
MethodDelegation.ImplementationDelegate.getMethodInvoker(TypeDescription instrumentedType)
Returns the method invoker responsible for invoking the delegation method.
|
MethodDelegationBinder.MethodInvoker |
MethodDelegation.ImplementationDelegate.ForStaticMethod.getMethodInvoker(TypeDescription instrumentedType) |
MethodDelegationBinder.MethodInvoker |
MethodDelegation.ImplementationDelegate.ForStaticField.getMethodInvoker(TypeDescription instrumentedType) |
MethodDelegationBinder.MethodInvoker |
MethodDelegation.ImplementationDelegate.ForInstanceField.getMethodInvoker(TypeDescription instrumentedType) |
MethodDelegationBinder.MethodInvoker |
MethodDelegation.ImplementationDelegate.ForConstruction.getMethodInvoker(TypeDescription instrumentedType) |
StackManipulation |
MethodDelegation.ImplementationDelegate.getPreparingStackAssignment(TypeDescription instrumentedType)
Returns the stack manipulation responsible for preparing the instance representing the implementation.
|
StackManipulation |
MethodDelegation.ImplementationDelegate.ForStaticMethod.getPreparingStackAssignment(TypeDescription instrumentedType) |
StackManipulation |
MethodDelegation.ImplementationDelegate.ForStaticField.getPreparingStackAssignment(TypeDescription instrumentedType) |
StackManipulation |
MethodDelegation.ImplementationDelegate.ForInstanceField.getPreparingStackAssignment(TypeDescription instrumentedType) |
StackManipulation |
MethodDelegation.ImplementationDelegate.ForConstruction.getPreparingStackAssignment(TypeDescription instrumentedType) |
FieldAccessor.AssignerConfigurable |
FieldAccessor.OwnerTypeLocatable.in(TypeDescription typeDescription)
Determines that a field should only be considered when it was defined in a given type.
|
FieldAccessor.AssignerConfigurable |
FieldAccessor.ForUnnamedField.in(TypeDescription typeDescription) |
FieldAccessor.AssignerConfigurable |
FieldAccessor.ForNamedField.in(TypeDescription typeDescription) |
InvokeDynamic.WithImplicitArguments |
InvokeDynamic.WithImplicitTarget.invoke(String methodName,
TypeDescription returnType)
Requests the bootstrap method to bind a method with the given return type.
|
InvokeDynamic.WithImplicitArguments |
InvokeDynamic.WithImplicitTarget.invoke(TypeDescription returnType)
Requests the bootstrap method to bind a method with the given return type.
|
Implementation.SpecialMethodInvocation |
Implementation.Target.invokeDefault(TypeDescription targetType,
String uniqueMethodSignature)
Creates a special method invocation for invoking a default method.
|
Implementation.SpecialMethodInvocation |
Implementation.Target.AbstractBase.invokeDefault(TypeDescription targetType,
String uniqueMethodSignature) |
FieldAccessor.FieldLocator |
FieldAccessor.FieldLocator.ForInstrumentedType.make(TypeDescription instrumentedType) |
FieldAccessor.FieldLocator |
FieldAccessor.FieldLocator.Factory.make(TypeDescription instrumentedType)
Creates a field locator.
|
FieldAccessor.FieldLocator |
FieldAccessor.FieldLocator.ForInstrumentedTypeHierarchy.Factory.make(TypeDescription instrumentedType) |
FieldAccessor.FieldLocator |
FieldAccessor.FieldLocator.ForGivenType.Factory.make(TypeDescription instrumentedType) |
static Implementation.SpecialMethodInvocation |
Implementation.SpecialMethodInvocation.Simple.of(MethodDescription methodDescription,
TypeDescription typeDescription)
Creates a special method invocation for a given invocation target.
|
static FieldAccessor.ForNamedField.PreparationHandler |
FieldAccessor.ForNamedField.PreparationHandler.FieldDefiner.of(String name,
TypeDescription typeDescription,
ModifierContributor.ForField... contributor)
Creates a new preparation handler that defines a given field.
|
MethodCall |
MethodCall.WithoutSpecifiedTarget.onInstanceField(TypeDescription typeDescription,
String fieldName)
Invokes the given method on an instance that is stored in an instance field.
|
InstrumentedType |
Forwarding.PreparationHandler.prepare(InstrumentedType instrumentedType,
String fieldName,
TypeDescription fieldType)
Prepares the instrumented type.
|
InstrumentedType |
Forwarding.PreparationHandler.ForInstanceField.prepare(InstrumentedType instrumentedType,
String fieldName,
TypeDescription fieldType) |
InstrumentedType |
Forwarding.PreparationHandler.ForStaticField.prepare(InstrumentedType instrumentedType,
String fieldName,
TypeDescription fieldType) |
InstrumentedType |
Forwarding.PreparationHandler.ForStaticInstance.prepare(InstrumentedType instrumentedType,
String fieldName,
TypeDescription fieldType) |
static Implementation |
DefaultMethodCall.prioritize(TypeDescription... prioritizedInterface)
Creates a
DefaultMethodCall implementation which searches the given list
of interface types for a suitable default method in their order. |
StackManipulation |
MethodCall.TargetHandler.resolve(MethodDescription methodDescription,
TypeDescription instrumentedType)
Creates a stack manipulation that represents the method's invocation.
|
StackManipulation |
MethodCall.TargetHandler.ForSelfOrStaticInvocation.resolve(MethodDescription methodDescription,
TypeDescription instrumentedType) |
StackManipulation |
MethodCall.TargetHandler.ForConstructingInvocation.resolve(MethodDescription methodDescription,
TypeDescription instrumentedType) |
StackManipulation |
MethodCall.TargetHandler.ForStaticField.resolve(MethodDescription methodDescription,
TypeDescription instrumentedType) |
StackManipulation |
MethodCall.TargetHandler.ForInstanceField.resolve(MethodDescription methodDescription,
TypeDescription instrumentedType) |
StackManipulation |
InvokeDynamic.TerminationHandler.resolve(MethodDescription interceptedMethod,
TypeDescription returnType,
Assigner assigner,
boolean dynamicallyTyped)
Returns a stack manipulation that handles the method return.
|
StackManipulation |
InvokeDynamic.TerminationHandler.ForMethodReturn.resolve(MethodDescription interceptedMethod,
TypeDescription returnType,
Assigner assigner,
boolean dynamicallyTyped) |
StackManipulation |
InvokeDynamic.TerminationHandler.ForChainedInvocation.resolve(MethodDescription interceptedMethod,
TypeDescription returnType,
Assigner assigner,
boolean dynamicallyTyped) |
InvokeDynamic.InvocationProvider.Target.Resolved |
InvokeDynamic.InvocationProvider.Target.resolve(TypeDescription instrumentedType,
Assigner assigner,
boolean dynamicallyTyped)
Resolves the target.
|
InvokeDynamic.InvocationProvider.Target.Resolved |
InvokeDynamic.InvocationProvider.Target.ForMethodDescription.resolve(TypeDescription instrumentedType,
Assigner assigner,
boolean dynamicallyTyped) |
InvokeDynamic.InvocationProvider.Target.Resolved |
InvokeDynamic.InvocationProvider.Default.Target.resolve(TypeDescription instrumentedType,
Assigner assigner,
boolean dynamicallyTyped) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
boolean dynamicallyTyped)
Resolves an argument provider.
|
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForInterceptedMethodInstanceAndParameters.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
boolean dynamicallyTyped) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForInterceptedMethodParameters.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
boolean dynamicallyTyped) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ConstantPoolWrapper.WrappingArgumentProvider.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
boolean dynamicallyTyped) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForThisInstance.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
boolean dynamicallyTyped) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForStaticField.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
boolean dynamicallyTyped) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForInstanceField.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
boolean dynamicallyTyped) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForExistingField.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
boolean dynamicallyTyped) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForMethodParameter.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
boolean dynamicallyTyped) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForExplicitTypedMethodParameter.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
boolean dynamicallyTyped) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForBooleanConstant.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
boolean dynamicallyTyped) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForByteConstant.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
boolean dynamicallyTyped) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForShortConstant.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
boolean dynamicallyTyped) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForCharacterConstant.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
boolean dynamicallyTyped) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForIntegerConstant.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
boolean dynamicallyTyped) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForLongConstant.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
boolean dynamicallyTyped) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForFloatConstant.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
boolean dynamicallyTyped) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForDoubleConstant.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
boolean dynamicallyTyped) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForStringConstant.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
boolean dynamicallyTyped) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForClassConstant.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
boolean dynamicallyTyped) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForEnumerationValue.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
boolean dynamicallyTyped) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForNullValue.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
boolean dynamicallyTyped) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForJavaInstance.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
boolean dynamicallyTyped) |
StackManipulation |
MethodCall.ArgumentLoader.resolve(TypeDescription instrumentedType,
MethodDescription interceptedMethod,
TypeDescription targetType,
Assigner assigner,
boolean dynamicallyTyped)
Loads the argument that is represented by this instance onto the operand stack.
|
StackManipulation |
MethodCall.ArgumentLoader.ForNullConstant.resolve(TypeDescription instrumentedType,
MethodDescription interceptedMethod,
TypeDescription targetType,
Assigner assigner,
boolean dynamicallyTyped) |
StackManipulation |
MethodCall.ArgumentLoader.ForThisReference.resolve(TypeDescription instrumentedType,
MethodDescription interceptedMethod,
TypeDescription targetType,
Assigner assigner,
boolean dynamicallyTyped) |
StackManipulation |
MethodCall.ArgumentLoader.ForOwnType.resolve(TypeDescription instrumentedType,
MethodDescription interceptedMethod,
TypeDescription targetType,
Assigner assigner,
boolean dynamicallyTyped) |
StackManipulation |
MethodCall.ArgumentLoader.ForMethodParameter.resolve(TypeDescription instrumentedType,
MethodDescription interceptedMethod,
TypeDescription targetType,
Assigner assigner,
boolean dynamicallyTyped) |
StackManipulation |
MethodCall.ArgumentLoader.ForStaticField.resolve(TypeDescription instrumentedType,
MethodDescription interceptedMethod,
TypeDescription targetType,
Assigner assigner,
boolean dynamicallyTyped) |
StackManipulation |
MethodCall.ArgumentLoader.ForInstanceField.resolve(TypeDescription instrumentedType,
MethodDescription interceptedMethod,
TypeDescription targetType,
Assigner assigner,
boolean dynamicallyTyped) |
StackManipulation |
MethodCall.ArgumentLoader.ForExistingField.resolve(TypeDescription instrumentedType,
MethodDescription interceptedMethod,
TypeDescription targetType,
Assigner assigner,
boolean dynamicallyTyped) |
StackManipulation |
MethodCall.ArgumentLoader.ForBooleanConstant.resolve(TypeDescription instrumentedType,
MethodDescription interceptedMethod,
TypeDescription targetType,
Assigner assigner,
boolean dynamicallyTyped) |
StackManipulation |
MethodCall.ArgumentLoader.ForByteConstant.resolve(TypeDescription instrumentedType,
MethodDescription interceptedMethod,
TypeDescription targetType,
Assigner assigner,
boolean dynamicallyTyped) |
StackManipulation |
MethodCall.ArgumentLoader.ForShortConstant.resolve(TypeDescription instrumentedType,
MethodDescription interceptedMethod,
TypeDescription targetType,
Assigner assigner,
boolean dynamicallyTyped) |
StackManipulation |
MethodCall.ArgumentLoader.ForCharacterConstant.resolve(TypeDescription instrumentedType,
MethodDescription interceptedMethod,
TypeDescription targetType,
Assigner assigner,
boolean dynamicallyTyped) |
StackManipulation |
MethodCall.ArgumentLoader.ForIntegerConstant.resolve(TypeDescription instrumentedType,
MethodDescription interceptedMethod,
TypeDescription targetType,
Assigner assigner,
boolean dynamicallyTyped) |
StackManipulation |
MethodCall.ArgumentLoader.ForLongConstant.resolve(TypeDescription instrumentedType,
MethodDescription interceptedMethod,
TypeDescription targetType,
Assigner assigner,
boolean dynamicallyTyped) |
StackManipulation |
MethodCall.ArgumentLoader.ForFloatConstant.resolve(TypeDescription instrumentedType,
MethodDescription interceptedMethod,
TypeDescription targetType,
Assigner assigner,
boolean dynamicallyTyped) |
StackManipulation |
MethodCall.ArgumentLoader.ForDoubleConstant.resolve(TypeDescription instrumentedType,
MethodDescription interceptedMethod,
TypeDescription targetType,
Assigner assigner,
boolean dynamicallyTyped) |
StackManipulation |
MethodCall.ArgumentLoader.ForTextConstant.resolve(TypeDescription instrumentedType,
MethodDescription interceptedMethod,
TypeDescription targetType,
Assigner assigner,
boolean dynamicallyTyped) |
StackManipulation |
MethodCall.ArgumentLoader.ForClassConstant.resolve(TypeDescription instrumentedType,
MethodDescription interceptedMethod,
TypeDescription targetType,
Assigner assigner,
boolean dynamicallyTyped) |
StackManipulation |
MethodCall.ArgumentLoader.ForEnumerationValue.resolve(TypeDescription instrumentedType,
MethodDescription interceptedMethod,
TypeDescription targetType,
Assigner assigner,
boolean dynamicallyTyped) |
StackManipulation |
MethodCall.ArgumentLoader.ForJavaInstance.resolve(TypeDescription instrumentedType,
MethodDescription interceptedMethod,
TypeDescription targetType,
Assigner assigner,
boolean dynamicallyTyped) |
static Implementation |
ExceptionMethod.throwing(TypeDescription exceptionType)
Creates an implementation that creates a new instance of the given isThrowable type on each method invocation
which is then thrown immediately.
|
static Implementation |
ExceptionMethod.throwing(TypeDescription exceptionType,
String message)
Creates an implementation that creates a new instance of the given isThrowable type on each method invocation
which is then thrown immediately.
|
static MethodDelegation |
MethodDelegation.to(TypeDescription typeDescription)
Creates an implementation where only
static methods of the given type are considered as binding targets. |
static MethodDelegation |
MethodDelegation.toConstructor(TypeDescription typeDescription)
Creates an implementation where method calls are delegated to constructor calls on the given type.
|
static Implementation |
Forwarding.toInstanceField(String fieldName,
TypeDescription fieldType)
Forwards all intercepted method invocations to an instance field of the instrumented class.
|
static MethodDelegation |
MethodDelegation.toInstanceField(TypeDescription typeDescription,
String fieldName)
Creates an implementation where method calls are delegated to an instance that is manually stored in a field
fieldName that is defined for the instrumented type. |
static MethodDelegation |
MethodDelegation.toInstanceField(TypeDescription typeDescription,
String fieldName,
MethodLookupEngine methodLookupEngine)
Identical to
MethodDelegation.toInstanceField(Class, String) but uses an
explicit MethodLookupEngine. |
static Implementation |
Forwarding.toStaticField(String fieldName,
TypeDescription fieldType)
Forwards all intercepted method invocations to a
static field of the instrumented class. |
static FixedValue.AssignerConfigurable |
FixedValue.value(TypeDescription fixedValue)
Returns the given type in form of a loaded type.
|
MethodCall |
MethodCall.with(TypeDescription... typeDescription)
Defines the given types to be provided as arguments to the invoked method where the represented types
are stored in the generated class's constant pool.
|
InvokeDynamic |
InvokeDynamic.withInstanceField(String fieldName,
TypeDescription fieldType)
Passes the value of the specified instance field to the bootstrapped method.
|
InvokeDynamic |
InvokeDynamic.AbstractDelegator.withInstanceField(String fieldName,
TypeDescription fieldType) |
MethodCall |
MethodCall.withInstanceField(TypeDescription typeDescription,
String name)
Defines a method call which fetches a value from an instance field.
|
InvokeDynamic |
InvokeDynamic.withNullValue(TypeDescription... typeDescription)
Passes
null values of the given types to the bootstrapped method. |
InvokeDynamic |
InvokeDynamic.AbstractDelegator.withNullValue(TypeDescription... typeDescription) |
InvokeDynamic |
InvokeDynamic.withThis(TypeDescription... typeDescription)
Passes references to
this onto the operand stack where the instance is represented as
the given types. |
InvokeDynamic |
InvokeDynamic.AbstractDelegator.withThis(TypeDescription... typeDescription) |
InvokeDynamic |
InvokeDynamic.withType(TypeDescription... typeDescription)
Hands the provided types to the dynamically bound method.
|
InvokeDynamic |
InvokeDynamic.AbstractDelegator.withType(TypeDescription... typeDescription) |
| Modifier and Type | Method and Description |
|---|---|
static Implementation |
DefaultMethodCall.prioritize(Collection<? extends TypeDescription> prioritizedInterfaces)
Creates a
DefaultMethodCall implementation which searches the given list
of interface types for a suitable default method in their order. |
| Constructor and Description |
|---|
Appender(TypeDescription instrumentedType)
Creates a new byte code appender for an invoke dynamic implementation.
|
Appender(TypeDescription instrumentedType)
Creates a new appender.
|
Appender(TypeDescription instrumentedType)
Creates a new appender.
|
Default(TypeDescription instrumentedType,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
InstrumentedType.TypeInitializer typeInitializer,
ClassFileVersion classFileVersion)
Creates a new implementation context.
|
ExceptionMethod(TypeDescription throwableType,
ExceptionMethod.ConstructionDelegate constructionDelegate)
Creates a new instance of an implementation for throwing throwables.
|
Factory(TypeDescription targetType)
Creates a new field locator factory for a given type.
|
FieldCacheEntry(StackManipulation fieldValue,
TypeDescription fieldType)
Creates a new field cache entry.
|
FieldDefiner(String name,
TypeDescription typeDescription,
int modifiers)
Creates a new field definer.
|
ForClassConstant(TypeDescription typeDescription)
Creates a new class constant representation.
|
ForClassConstant(TypeDescription typeDescription)
Creates a new argument provider for the given type description.
|
ForConstruction(TypeDescription typeDescription)
Creates a new constructor implementation.
|
ForDefaultConstructor(TypeDescription exceptionType)
Creates a new construction delegate that calls a default constructor.
|
ForExplicitType(TypeDescription typeDescription)
Creates a new return type provider for an explicit return type.
|
ForExplicitTypedMethodParameter(int index,
TypeDescription typeDescription)
Creates an argument provider for an argument of the intercepted method.
|
ForGivenType(TypeDescription targetType,
TypeDescription instrumentedType)
Creates a new field locator for a given type.
|
ForInstanceField(String fieldName,
TypeDescription fieldType)
Creates a new target handler for storing a method invocation target in an
instance field.
|
ForInstanceField(String fieldName,
TypeDescription fieldType)
Creates a new argument provider that provides a value from an instance field.
|
ForInstanceField(TypeDescription fieldType,
String fieldName)
Creates a new instance field implementation delegate.
|
ForInstanceField(TypeDescription fieldType,
String fieldName)
Creates a new argument loader for a value of an instance field.
|
ForInstrumentedTypeHierarchy(TypeDescription instrumentedType)
Creates a field locator that follows the type hierarchy.
|
ForNullValue(TypeDescription typeDescription)
Creates a new argument provider for the
null value. |
ForStaticField(Object value,
TypeDescription typeDescription)
Creates a new argument provider that stores the given value in a static field.
|
ForStringConstructor(TypeDescription exceptionType,
String message)
Creates a new construction delegate that calls a constructor by handing it the given string.
|
ForThisInstance(TypeDescription typeDescription)
Creates a new argument provider for the instance of the instrumented type.
|
Forwarding(String fieldName,
TypeDescription fieldType,
Forwarding.PreparationHandler preparationHandler)
Creates a new forwarding implementation.
|
Simple(MethodDescription methodDescription,
TypeDescription typeDescription,
StackManipulation stackManipulation)
Creates a new legal special method invocation.
|
Simple(StackManipulation stackManipulation,
String internalName,
TypeDescription returnType,
List<TypeDescription> parameterTypes)
Creates a new simple instance.
|
Simple(StackManipulation stackManipulation,
TypeDescription loadedType)
Creates a simple resolved argument provider.
|
Target(String internalName,
TypeDescription returnType,
List<InvokeDynamic.InvocationProvider.ArgumentProvider> argumentProviders,
MethodDescription instrumentedMethod)
Creates a new target.
|
| Constructor and Description |
|---|
Appender(Implementation.Target implementationTarget,
List<TypeDescription> prioritizedInterfaces)
Creates a new appender for implementing a
DefaultMethodCall. |
DefaultMethodCall(List<TypeDescription> prioritizedInterfaces)
Creates a new
DefaultMethodCall implementation for a given list of
prioritized interfaces. |
Simple(StackManipulation stackManipulation,
List<TypeDescription> loadedTypes)
Creates a simple resolved argument provider.
|
Simple(StackManipulation stackManipulation,
String internalName,
TypeDescription returnType,
List<TypeDescription> parameterTypes)
Creates a new simple instance.
|
| Modifier and Type | Method and Description |
|---|---|
static void |
AnnotationAppender.Default.apply(AnnotationVisitor annotationVisitor,
TypeDescription valueType,
String name,
Object value)
Performs the writing of a given annotation value to an annotation visitor.
|
void |
TypeAttributeAppender.apply(ClassVisitor classVisitor,
TypeDescription typeDescription)
Applies this type attribute appender.
|
void |
TypeAttributeAppender.NoOp.apply(ClassVisitor classVisitor,
TypeDescription typeDescription) |
void |
TypeAttributeAppender.ForSuperType.apply(ClassVisitor classVisitor,
TypeDescription typeDescription) |
void |
TypeAttributeAppender.ForAnnotation.apply(ClassVisitor classVisitor,
TypeDescription typeDescription) |
void |
TypeAttributeAppender.ForType.apply(ClassVisitor classVisitor,
TypeDescription typeDescription) |
void |
TypeAttributeAppender.Compound.apply(ClassVisitor classVisitor,
TypeDescription typeDescription) |
MethodAttributeAppender |
MethodAttributeAppender.NoOp.make(TypeDescription typeDescription) |
MethodAttributeAppender |
MethodAttributeAppender.ForInstrumentedMethod.make(TypeDescription typeDescription) |
MethodAttributeAppender |
MethodAttributeAppender.Factory.make(TypeDescription typeDescription)
Returns a method attribute appender that is applicable for a given type description.
|
MethodAttributeAppender |
MethodAttributeAppender.Factory.Compound.make(TypeDescription typeDescription) |
MethodAttributeAppender |
MethodAttributeAppender.ForAnnotation.make(TypeDescription typeDescription) |
MethodAttributeAppender |
MethodAttributeAppender.ForMethod.make(TypeDescription typeDescription) |
FieldAttributeAppender |
FieldAttributeAppender.NoOp.make(TypeDescription typeDescription) |
FieldAttributeAppender |
FieldAttributeAppender.Factory.make(TypeDescription typeDescription)
Returns a field attribute appender that is applicable for a given type description.
|
FieldAttributeAppender |
FieldAttributeAppender.Factory.Compound.make(TypeDescription typeDescription) |
FieldAttributeAppender |
FieldAttributeAppender.ForAnnotation.make(TypeDescription typeDescription) |
FieldAttributeAppender |
FieldAttributeAppender.ForField.make(TypeDescription typeDescription) |
| Constructor and Description |
|---|
ForType(TypeDescription typeDescription,
AnnotationAppender.ValueFilter valueFilter)
Creates a new attribute appender that writes all annotations declared for the given type description.
|
| Modifier and Type | Method and Description |
|---|---|
Implementation.SpecialMethodInvocation |
TypeProxy.InvocationFactory.invoke(Implementation.Target implementationTarget,
TypeDescription proxiedType,
MethodDescription instrumentedMethod)
Creates a special method invocation to implement for a given method.
|
String |
AuxiliaryType.NamingStrategy.name(AuxiliaryType auxiliaryType,
TypeDescription instrumentedType)
NAmes an auxiliary type.
|
String |
AuxiliaryType.NamingStrategy.SuffixingRandom.name(AuxiliaryType auxiliaryType,
TypeDescription instrumentedType) |
MethodLookupEngine.Finding |
TrivialType.process(TypeDescription typeDescription) |
MethodLookupEngine.Finding |
MethodCallProxy.ProxyMethodLookupEngine.process(TypeDescription typeDescription) |
| Constructor and Description |
|---|
Appender(TypeDescription instrumentedType)
Creates a new appender.
|
ForDefaultMethod(TypeDescription proxiedType,
Implementation.Target implementationTarget,
boolean serializableProxy)
Creates a new proxy creation for a default interface type proxy.
|
ForSuperMethodByConstructor(TypeDescription proxiedType,
Implementation.Target implementationTarget,
List<TypeDescription> constructorParameters,
boolean ignoreFinalizer,
boolean serializableProxy)
Creates a new stack operation for creating a type proxy by calling one of its constructors.
|
ForSuperMethodByReflectionFactory(TypeDescription proxiedType,
Implementation.Target implementationTarget,
boolean ignoreFinalizer,
boolean serializableProxy)
Creates a new stack operation for reflectively creating a type proxy for the given arguments.
|
TypeProxy(TypeDescription proxiedType,
Implementation.Target implementationTarget,
TypeProxy.InvocationFactory invocationFactory,
boolean ignoreFinalizer,
boolean serializableProxy)
Creates a new type proxy.
|
| Constructor and Description |
|---|
ForSuperMethodByConstructor(TypeDescription proxiedType,
Implementation.Target implementationTarget,
List<TypeDescription> constructorParameters,
boolean ignoreFinalizer,
boolean serializableProxy)
Creates a new stack operation for creating a type proxy by calling one of its constructors.
|
| Modifier and Type | Method and Description |
|---|---|
static ArgumentTypeResolver.PrimitiveTypePrecedence |
ArgumentTypeResolver.PrimitiveTypePrecedence.forPrimitive(TypeDescription typeDescription)
Locates the primitive type precedence for a given type.
|
| Constructor and Description |
|---|
Virtual(TypeDescription typeDescription)
Creates an immutable method invoker that dispatches all methods on a given type.
|
| Modifier and Type | Method and Description |
|---|---|
TypeDescription |
Pipe.Binder.PrecomputedFinding.getTypeDescription() |
TypeDescription |
Morph.Binder.PrecomputedFinding.getTypeDescription() |
protected abstract TypeDescription |
FieldProxy.Binder.AccessType.proxyType(MethodDescription getterMethod,
MethodDescription setterMethod)
Locates the type to be implemented by a field accessor proxy.
|
| Modifier and Type | Method and Description |
|---|---|
Map<TypeDescription,Set<MethodDescription>> |
Pipe.Binder.PrecomputedFinding.getInvokableDefaultMethods() |
Map<TypeDescription,Set<MethodDescription>> |
Morph.Binder.PrecomputedFinding.getInvokableDefaultMethods() |
| Modifier and Type | Method and Description |
|---|---|
static TargetMethodAnnotationDrivenBinder.ParameterBinder<Pipe> |
Pipe.Binder.install(TypeDescription typeDescription)
Installs a given type for use on a
Pipe
annotation. |
static TargetMethodAnnotationDrivenBinder.ParameterBinder<Morph> |
Morph.Binder.install(TypeDescription typeDescription)
Installs a given type for use on a
Morph
annotation. |
static TargetMethodAnnotationDrivenBinder.ParameterBinder<FieldProxy> |
FieldProxy.Binder.install(TypeDescription getterType,
TypeDescription setterType)
Creates a binder by installing two proxy types which are implemented by this binder if a field getter
or a field setter is requested by using the
FieldProxy annotation. |
protected abstract FieldProxy.Binder.FieldLocator.LookupEngine |
FieldProxy.Binder.FieldLocator.lookup(TypeDescription typeDescription,
TypeDescription instrumentedType)
Locates a field of a given name on a specific type.
|
protected FieldProxy.Binder.FieldLocator.LookupEngine |
FieldProxy.Binder.FieldLocator.Legal.lookup(TypeDescription typeDescription,
TypeDescription instrumentedType) |
protected FieldProxy.Binder.FieldLocator.LookupEngine |
FieldProxy.Binder.FieldLocator.Illegal.lookup(TypeDescription typeDescription,
TypeDescription instrumentedType) |
protected abstract MethodDelegationBinder.ParameterBinding<?> |
Argument.BindingMechanic.makeBinding(TypeDescription sourceType,
TypeDescription targetType,
int sourceParameterIndex,
Assigner assigner,
boolean dynamicallyTyped,
int parameterOffset)
Creates a binding that corresponds to this binding mechanic.
|
protected static FieldValue.Binder.FieldLocator |
FieldValue.Binder.FieldLocator.of(TypeDescription typeDescription,
TypeDescription instrumentedType)
Creates a field locator for the given type and instrumented type.
|
protected static FieldValue.Binder.FieldLocator |
FieldValue.Binder.FieldLocator.ForSpecificType.of(TypeDescription typeDescription,
TypeDescription instrumentedType)
Creates a field locator that locates a field within the given type only if that type is within the
instrumented type's type hierarchy.
|
MethodLookupEngine.Finding |
Pipe.Binder.process(TypeDescription typeDescription) |
MethodLookupEngine.Finding |
Morph.Binder.process(TypeDescription typeDescription) |
protected abstract StackManipulation |
Super.Instantiation.proxyFor(TypeDescription parameterType,
Implementation.Target implementationTarget,
AnnotationDescription.Loadable<Super> annotation)
Creates a stack manipulation which loads a
super-call proxy onto the stack. |
protected abstract FieldProxy.Binder.FieldLocator.Resolution |
FieldProxy.Binder.FieldLocator.LookupEngine.resolve(TypeDescription instrumentedType,
boolean staticMethod)
Locates a field if possible and returns a corresponding resolution.
|
protected FieldProxy.Binder.FieldLocator.Resolution |
FieldProxy.Binder.FieldLocator.LookupEngine.Illegal.resolve(TypeDescription instrumentedType,
boolean staticMethod) |
protected FieldProxy.Binder.FieldLocator.Resolution |
FieldProxy.Binder.FieldLocator.LookupEngine.ForHierarchy.resolve(TypeDescription instrumentedType,
boolean staticMethod) |
protected FieldProxy.Binder.FieldLocator.Resolution |
FieldProxy.Binder.FieldLocator.LookupEngine.ForExplicitType.resolve(TypeDescription instrumentedType,
boolean staticMethod) |
| Constructor and Description |
|---|
AccessorProxy(FieldDescription accessedField,
Assigner assigner,
TypeDescription instrumentedType,
FieldProxy.Binder.AccessType accessType,
boolean serializableProxy) |
Explicit(TypeDescription typeDescription)
Creates a new explicit default method locator.
|
Explicit(TypeDescription typeDescription)
Creates a new explicit default method locator.
|
ForExplicitType(String fieldName,
TypeDescription typeDescription)
Creates a new lookup engine for a given type.
|
ForFieldInHierarchy(TypeDescription instrumentedType)
Creates a new field locator for locating a field in the instrumented type's class hierarchy.
|
ForSpecificType(TypeDescription typeDescription,
TypeDescription instrumentedType)
Creates a new field locator for looking up a field within a specific type.
|
InstanceFieldConstructor(TypeDescription instrumentedType)
Creates a new instance field constructor implementation.
|
InstanceFieldConstructor(TypeDescription instrumentedType)
Creates a new implementation for implementing a field accessor proxy's constructor when accessing
a non-static field.
|
PrecomputedFinding(TypeDescription typeDescription)
Creates a precomputed finding.
|
PrecomputedFinding(TypeDescription typeDescription)
Creates a new precomputed finding.
|
Redirection(TypeDescription forwardingType,
MethodDescription sourceMethod,
Assigner assigner,
boolean serializableProxy,
MethodLookupEngine.Factory methodLookupEngineFactory)
Creates a new redirection.
|
RedirectionProxy(TypeDescription morphingType,
TypeDescription instrumentedType,
Implementation.SpecialMethodInvocation specialMethodInvocation,
Assigner assigner,
boolean serializableProxy,
MethodLookupEngine.Factory methodLookupEngineFactory)
Creates a new redirection proxy.
|
| Constructor and Description |
|---|
DelegationProcessor(Map<TypeDescription,TargetMethodAnnotationDrivenBinder.ParameterBinder<?>> parameterBinders)
Creates a new delegation processor.
|
| Modifier and Type | Method and Description |
|---|---|
static StackManipulation |
Duplication.duplicate(TypeDescription typeDescription)
Duplicates a value given its type.
|
static StackManipulation |
TypeCreation.forType(TypeDescription typeDescription)
Creates a type creation for the given type.
|
static StackManipulation |
Removal.pop(TypeDescription typeDescription)
Removes a value from the operand stack dependant of its size.
|
| Constructor and Description |
|---|
TypeCreation(TypeDescription typeDescription)
Constructs a new type creation.
|
| Modifier and Type | Method and Description |
|---|---|
StackManipulation |
Assigner.assign(TypeDescription sourceType,
TypeDescription targetType,
boolean dynamicallyTyped) |
StackManipulation |
Assigner.EqualTypesOnly.assign(TypeDescription sourceType,
TypeDescription targetType,
boolean dynamicallyTyped) |
StackManipulation |
Assigner.Refusing.assign(TypeDescription sourceType,
TypeDescription targetType,
boolean dynamicallyTyped) |
static StackManipulation |
TypeCasting.to(TypeDescription typeDescription)
Creates a casting to the given, non-primitive type.
|
| Constructor and Description |
|---|
TypeCasting(TypeDescription typeDescription)
Creates a new type casting.
|
| Modifier and Type | Method and Description |
|---|---|
StackManipulation |
VoidAwareAssigner.assign(TypeDescription sourceType,
TypeDescription targetType,
boolean dynamicallyTyped) |
StackManipulation |
PrimitiveTypeAwareAssigner.assign(TypeDescription sourceType,
TypeDescription targetType,
boolean dynamicallyTyped) |
StackManipulation |
PrimitiveBoxingDelegate.assignBoxedTo(TypeDescription targetType,
Assigner chainedAssigner,
boolean dynamicallyTyped)
Creates a stack manipulation that boxes the represented primitive type and applies a chained assignment
to the result of this boxing operation.
|
StackManipulation |
PrimitiveUnboxingDelegate.ExplicitlyTypedUnboxingResponsible.assignUnboxedTo(TypeDescription targetType,
Assigner assigner,
boolean dynamicallyTyped) |
StackManipulation |
PrimitiveUnboxingDelegate.UnboxingResponsible.assignUnboxedTo(TypeDescription targetType,
Assigner assigner,
boolean dynamicallyTyped)
Attempts to unbox the represented type in order to assign the unboxed value to the given target type
while using the assigner that is provided by the method call.
|
StackManipulation |
PrimitiveUnboxingDelegate.ImplicitlyTypedUnboxingResponsible.assignUnboxedTo(TypeDescription targetType,
Assigner assigner,
boolean dynamicallyTyped) |
static PrimitiveWideningDelegate |
PrimitiveWideningDelegate.forPrimitive(TypeDescription typeDescription)
Locates the delegate that is capable of widening the given type into another type.
|
protected static PrimitiveUnboxingDelegate |
PrimitiveUnboxingDelegate.forPrimitive(TypeDescription typeDescription)
Locates a primitive unboxing delegate for a given primitive type.
|
static PrimitiveBoxingDelegate |
PrimitiveBoxingDelegate.forPrimitive(TypeDescription typeDescription)
Locates a boxing delegate for a given primitive type.
|
static PrimitiveUnboxingDelegate.UnboxingResponsible |
PrimitiveUnboxingDelegate.forReferenceType(TypeDescription typeDescription)
Creates an unboxing responsible that is capable of unboxing a wrapper type.
|
StackManipulation |
PrimitiveWideningDelegate.widenTo(TypeDescription typeDescription)
Attempts to widen the represented type into another type.
|
| Constructor and Description |
|---|
ImplicitlyTypedUnboxingResponsible(TypeDescription originalType)
Creates a new implicitly typed unboxing responsible.
|
| Modifier and Type | Method and Description |
|---|---|
StackManipulation |
ReferenceTypeAwareAssigner.assign(TypeDescription sourceType,
TypeDescription targetType,
boolean dynamicallyTyped) |
| Modifier and Type | Method and Description |
|---|---|
TypeDescription |
CollectionFactory.getComponentType()
The component type of this factory.
|
TypeDescription |
ArrayFactory.getComponentType() |
| Modifier and Type | Method and Description |
|---|---|
static ArrayFactory |
ArrayFactory.forType(TypeDescription componentType)
Creates a new array factory for a given component type.
|
static ArrayAccess |
ArrayAccess.of(TypeDescription componentType)
Locates an array accessor by the array's component type.
|
| Constructor and Description |
|---|
ArrayFactory(TypeDescription componentType,
ArrayFactory.ArrayCreator arrayCreator)
Creates a new array factory with a given
ArrayFactory.ArrayCreator
without inferring the type from the component type. |
ForReferenceType(TypeDescription referenceType)
Creates a new array creator for a reference type.
|
| Modifier and Type | Method and Description |
|---|---|
static StackManipulation |
DefaultValue.of(TypeDescription typeDescription)
Creates a stack assignment that loads the default value for a given type.
|
static StackManipulation |
ClassConstant.of(TypeDescription typeDescription)
Returns a stack manipulation that loads a
Class type onto the operand stack which
represents the given type. |
| Constructor and Description |
|---|
ForReferenceType(TypeDescription typeDescription)
Creates a stack manipulation that represents loading a class constant onto the stack.
|
| Modifier and Type | Method and Description |
|---|---|
StackManipulation |
MethodInvocation.IllegalInvocation.dynamic(String methodName,
TypeDescription returnType,
List<? extends TypeDescription> methodType,
List<?> arguments) |
StackManipulation |
MethodInvocation.WithImplicitInvocationTargetType.dynamic(String methodName,
TypeDescription returnType,
List<? extends TypeDescription> methodType,
List<?> arguments)
Invokes the method as a bootstrap method to bind a call site with the given properties.
|
StackManipulation |
MethodInvocation.Invocation.dynamic(String methodName,
TypeDescription returnType,
List<? extends TypeDescription> methodType,
List<?> arguments) |
static MethodVariableAccess |
MethodVariableAccess.forType(TypeDescription typeDescription)
Locates the correct accessor for a variable of a given type.
|
static StackManipulation |
MethodReturn.returning(TypeDescription typeDescription)
Returns a method return corresponding to a given type.
|
StackManipulation |
MethodInvocation.IllegalInvocation.special(TypeDescription invocationTarget) |
StackManipulation |
MethodInvocation.WithImplicitInvocationTargetType.special(TypeDescription invocationTarget)
Transforms this method invocation into a special invocation on the given type.
|
StackManipulation |
MethodInvocation.Invocation.special(TypeDescription invocationTarget) |
StackManipulation |
MethodInvocation.IllegalInvocation.virtual(TypeDescription invocationTarget) |
StackManipulation |
MethodInvocation.WithImplicitInvocationTargetType.virtual(TypeDescription invocationTarget)
Transforms this method invocation into a virtual (or interface) method invocation on the given type.
|
StackManipulation |
MethodInvocation.Invocation.virtual(TypeDescription invocationTarget) |
StackManipulation |
MethodVariableAccess.TypeCastingHandler.wrapNext(StackManipulation variableAccess,
TypeDescription parameterType)
Returns the given stack manipulation while possibly wrapping the operation by a type casting
if this is required.
|
StackManipulation |
MethodVariableAccess.TypeCastingHandler.NoOp.wrapNext(StackManipulation variableAccess,
TypeDescription parameterType) |
StackManipulation |
MethodVariableAccess.TypeCastingHandler.ForBridgeTarget.wrapNext(StackManipulation variableAccess,
TypeDescription parameterType) |
| Modifier and Type | Method and Description |
|---|---|
StackManipulation |
MethodInvocation.IllegalInvocation.dynamic(String methodName,
TypeDescription returnType,
List<? extends TypeDescription> methodType,
List<?> arguments) |
StackManipulation |
MethodInvocation.WithImplicitInvocationTargetType.dynamic(String methodName,
TypeDescription returnType,
List<? extends TypeDescription> methodType,
List<?> arguments)
Invokes the method as a bootstrap method to bind a call site with the given properties.
|
StackManipulation |
MethodInvocation.Invocation.dynamic(String methodName,
TypeDescription returnType,
List<? extends TypeDescription> methodType,
List<?> arguments) |
| Constructor and Description |
|---|
DynamicInvocation(String methodName,
TypeDescription returnType,
TypeList parameterTypes,
MethodDescription bootstrapMethod,
List<?> arguments)
Creates a new dynamic method invocation.
|
Invocation(MethodDescription methodDescription,
TypeDescription typeDescription)
Creates an invocation of a given method on a given invocation target type.
|
| Modifier and Type | Class and Description |
|---|---|
class |
DeclaringFieldMatcher<T extends TypeDescription>
An element matcher that checks if a type description declares fields of a given property.
|
class |
DeclaringMethodMatcher<T extends TypeDescription>
An element matcher that checks if a type description declares methods of a given property.
|
class |
InheritedAnnotationMatcher<T extends TypeDescription>
An element matcher that matches the list of inherited annotations of a type description.
|
class |
SubTypeMatcher<T extends TypeDescription>
An element matcher that matches its argument for being another type's subtype.
|
class |
SuperTypeMatcher<T extends TypeDescription>
An element matcher that matches its argument for being another type's super type.
|
| Modifier and Type | Method and Description |
|---|---|
static <T extends TypeDescription> |
ElementMatchers.anyOf(Class<?>... value)
Creates a matcher that matches any of the given types as
TypeDescriptions
by the Object.equals(Object) method. |
static <T extends TypeDescription> |
ElementMatchers.declaresField(ElementMatcher<? super FieldDescription> fieldMatcher)
Matches a type by a another matcher that is applied on any of its declared fields.
|
static <T extends TypeDescription> |
ElementMatchers.declaresMethod(ElementMatcher<? super MethodDescription> methodMatcher)
Matches a type by a another matcher that is applied on any of its declared methods.
|
static <T extends TypeDescription> |
ElementMatchers.hasAnnotation(ElementMatcher<? super AnnotationDescription> matcher)
Matches a list of annotations by a given matcher on a type that declared these annotations or inherited them
from its super classes.
|
static <T extends TypeDescription> |
ElementMatchers.inheritsAnnotation(Class<?> type)
Matches any annotations by their type on a type that declared these annotations or inherited them from its
super classes.
|
static <T extends TypeDescription> |
ElementMatchers.inheritsAnnotation(ElementMatcher<? super TypeDescription> matcher)
Matches any annotations by a given matcher on a type that declared these annotations or inherited them from its
super classes.
|
static <T extends TypeDescription> |
ElementMatchers.inheritsAnnotation(TypeDescription typeDescription)
Matches any annotations by their type on a type that declared these annotations or inherited them from its
super classes.
|
static <T extends TypeDescription> |
ElementMatchers.is(Class<?> type)
Exactly matches a given type as a
TypeDescription. |
static <T extends TypeDescription> |
ElementMatchers.is(TypeDescription typeDescription)
Exactly matches a given
TypeDescription. |
static <T extends TypeDescription> |
ElementMatchers.isSubTypeOf(Class<?> type)
Matches any type description that is a subtype of the given type.
|
static <T extends TypeDescription> |
ElementMatchers.isSubTypeOf(TypeDescription typeDescription)
Matches any type description that is a subtype of the given type.
|
static <T extends TypeDescription> |
ElementMatchers.isSuperTypeOf(Class<?> type)
Matches any type description that is a super type of the given type.
|
static <T extends TypeDescription> |
ElementMatchers.isSuperTypeOf(TypeDescription typeDescription)
Matches any type description that is a super type of the given type.
|
static <T extends TypeDescription> |
ElementMatchers.noneOf(Class<?>... value)
Creates a matcher that matches none of the given types as
TypeDescriptions
by the Object.equals(Object) method. |
| Modifier and Type | Method and Description |
|---|---|
static <T extends MethodDescription> |
ElementMatchers.canThrow(TypeDescription exceptionType)
Matches a
MethodDescription by its capability to throw a given
checked exception. |
static <T extends TypeDescription> |
ElementMatchers.inheritsAnnotation(TypeDescription typeDescription)
Matches any annotations by their type on a type that declared these annotations or inherited them from its
super classes.
|
static <T extends TypeDescription> |
ElementMatchers.is(TypeDescription typeDescription)
Exactly matches a given
TypeDescription. |
static <T extends AnnotatedCodeElement> |
ElementMatchers.isAnnotatedWith(TypeDescription typeDescription)
Matches an
AnnotatedCodeElement for declared annotations. |
static <T extends ByteCodeElement> |
ElementMatchers.isDeclaredBy(TypeDescription type)
Matches a
ByteCodeElement for being declared by a given
TypeDescription. |
static <T extends MethodDescription> |
ElementMatchers.isGetter(TypeDescription typeDescription)
Matches any Java bean getter method which returns the given type.
|
static <T extends MethodDescription> |
ElementMatchers.isSetter(TypeDescription typeDescription)
Matches any Java bean setter method which takes an argument the given type.
|
static <T extends TypeDescription> |
ElementMatchers.isSubTypeOf(TypeDescription typeDescription)
Matches any type description that is a subtype of the given type.
|
static <T extends TypeDescription> |
ElementMatchers.isSuperTypeOf(TypeDescription typeDescription)
Matches any type description that is a super type of the given type.
|
static <T extends ByteCodeElement> |
ElementMatchers.isVisibleTo(TypeDescription typeDescription)
Matches a
ByteCodeElement that is visible to a given
TypeDescription. |
ElementMatcher<? super MethodDescription> |
LatentMethodMatcher.resolve(TypeDescription instrumentedType)
Resolves the latent method matcher.
|
ElementMatcher<? super MethodDescription> |
LatentMethodMatcher.Resolved.resolve(TypeDescription instrumentedType) |
static <T extends MethodDescription> |
ElementMatchers.returns(TypeDescription typeDescription)
Matches
MethodDescriptions that returns a given
TypeDescription. |
static <T extends MethodDescription> |
ElementMatchers.takesArguments(TypeDescription... typeDescription)
Matches a
MethodDescription by its exact parameter types. |
| Modifier and Type | Method and Description |
|---|---|
static <T extends TypeDescription> |
ElementMatchers.inheritsAnnotation(ElementMatcher<? super TypeDescription> matcher)
Matches any annotations by a given matcher on a type that declared these annotations or inherited them from its
super classes.
|
static <T extends AnnotatedCodeElement> |
ElementMatchers.isAnnotatedWith(ElementMatcher<? super TypeDescription> matcher)
Matches an
AnnotatedCodeElement for declared annotations. |
static <T extends ByteCodeElement> |
ElementMatchers.isDeclaredBy(ElementMatcher<? super TypeDescription> matcher)
Matches a
ByteCodeElement for being declared by a
TypeDescription that is matched by the given matcher. |
static <T extends MethodDescription> |
ElementMatchers.isGetter(ElementMatcher<? super TypeDescription> matcher)
Matches any Java bean getter method which returns an value with a type matches the supplied matcher.
|
static <T extends MethodDescription> |
ElementMatchers.isSetter(ElementMatcher<? super TypeDescription> matcher)
Matches any Java bean setter method which takes an argument that matches the supplied matcher.
|
static <T extends MethodDescription> |
ElementMatchers.returns(ElementMatcher<? super TypeDescription> matcher)
Matches
MethodDescriptions that matches a matched method's
return type. |
static <T extends MethodDescription> |
ElementMatchers.takesArguments(ElementMatcher<? super Iterable<? extends TypeDescription>> matchers)
Matches a
MethodDescription by applying an iterable collection
of element matcher on any parameter's TypeDescription. |
static <T extends MethodDescription> |
ElementMatchers.takesArguments(Iterable<? extends TypeDescription> typeDescriptions)
Matches a
MethodDescription by its exact parameter types. |
static <T extends MethodDescription> |
ElementMatchers.throwing(ElementMatcher<? super List<? extends TypeDescription>> exceptionMatcher)
Matches a
MethodDescription by its declared exceptions. |
| Constructor and Description |
|---|
SubTypeMatcher(TypeDescription typeDescription)
Creates a new matcher for matching its input for being a sub type of the given
typeDescription. |
SuperTypeMatcher(TypeDescription typeDescription)
Creates a new matcher for matching its input for being a super type of the given
typeDescription. |
VisibilityMatcher(TypeDescription typeDescription)
Creates a matcher that validates that a byte code element can be seen by a given type.
|
| Constructor and Description |
|---|
AnnotationTypeMatcher(ElementMatcher<? super TypeDescription> typeMatcher)
Creates a new matcher for an annotation description's type.
|
DeclaringTypeMatcher(ElementMatcher<? super TypeDescription> typeMatcher)
Creates a new matcher for the declaring type of an element.
|
MethodReturnTypeMatcher(ElementMatcher<? super TypeDescription> typeMatcher)
Creates a new matcher for a matched element's return type.
|
| Modifier and Type | Class and Description |
|---|---|
static class |
TypePool.LazyTypeDescription
A type description that looks up any referenced
ByteCodeElement or
AnnotationDescription by querying a type pool at lookup time. |
| Modifier and Type | Field and Description |
|---|---|
protected static Map<String,TypeDescription> |
TypePool.AbstractBase.PRIMITIVE_TYPES
A map of primitive types by their name.
|
| Modifier and Type | Method and Description |
|---|---|
TypeDescription |
TypePool.LazyTypeDescription.LazyTypeList.get(int index) |
TypeDescription |
TypePool.LazyTypeDescription.getDeclaringType() |
TypeDescription |
TypePool.LazyTypeDescription.getEnclosingType() |
TypeDescription |
TypePool.LazyTypeDescription.DeclarationContext.getEnclosingType(TypePool typePool)
Returns the enclosing type or
null if no such type exists. |
TypeDescription |
TypePool.LazyTypeDescription.DeclarationContext.SelfDeclared.getEnclosingType(TypePool typePool) |
TypeDescription |
TypePool.LazyTypeDescription.DeclarationContext.DeclaredInType.getEnclosingType(TypePool typePool) |
TypeDescription |
TypePool.LazyTypeDescription.DeclarationContext.DeclaredInMethod.getEnclosingType(TypePool typePool) |
TypeDescription |
TypePool.AbstractBase.RawEnumerationValue.LazyEnumerationDescription.getEnumerationType() |
TypeDescription |
TypePool.LazyTypeDescription.getSupertype() |
TypeDescription |
TypePool.Resolution.resolve()
Resolves this resolution to the represented type description.
|
TypeDescription |
TypePool.Resolution.Simple.resolve() |
TypeDescription |
TypePool.Resolution.Illegal.resolve() |
TypeDescription |
TypePool.AbstractBase.ArrayTypeResolution.resolve() |
TypeDescription |
TypePool.AbstractBase.RawTypeValue.resolve() |
protected TypeDescription |
TypePool.Default.TypeExtractor.toTypeDescription()
Creates a type description from all data that is currently collected.
|
| Modifier and Type | Method and Description |
|---|---|
protected TypeList |
TypePool.LazyTypeDescription.LazyTypeList.wrap(List<TypeDescription> values) |
| Constructor and Description |
|---|
Simple(TypeDescription typeDescription)
Creates a new successful resolution of a given type description.
|
| Modifier and Type | Method and Description |
|---|---|
static <T extends TypeDescription> |
ByteBuddyCommons.isAnnotation(T typeDescriptions)
Validates if a type is an annotation type.
|
static <T extends TypeDescription> |
ByteBuddyCommons.isExtendable(T typeDescription)
Validates that a type can be implemented, i.e.
|
static <T extends Iterable<? extends TypeDescription>> |
ByteBuddyCommons.isInterface(T typeDescriptions)
Validates if a list of type only contains interfaces.
|
static <T extends TypeDescription> |
ByteBuddyCommons.isInterface(T typeDescription)
Validates if a type represents an interface.
|
static <T extends TypeDescription> |
ByteBuddyCommons.isInterface(T[] typeDescription)
Validates if an array of type only contains interfaces.
|
static <T extends Iterable<? extends TypeDescription>> |
ByteBuddyCommons.isThrowable(T types)
Checks if given types can all be thrown, i.e.
|
static <T extends Iterable<? extends TypeDescription>> |
ByteBuddyCommons.nonVoid(T typeDescriptions)
Validates that type descriptions do not represent the
void type. |
static <T extends TypeDescription> |
ByteBuddyCommons.nonVoid(T typeDescription)
Validates that a type description is not representing the
void type. |
| Modifier and Type | Method and Description |
|---|---|
TypeDescription |
JavaInstance.getInstanceType()
Returns a description of the type of the represented instance or at least a stub.
|
TypeDescription |
JavaInstance.MethodType.getInstanceType() |
TypeDescription |
JavaInstance.MethodHandle.getInstanceType() |
TypeDescription |
JavaInstance.MethodHandle.getOwnerType()
Returns the owner type of this instance.
|
TypeDescription |
JavaInstance.MethodType.getReturnType()
Returns the return type of this method type.
|
TypeDescription |
JavaInstance.MethodHandle.getReturnType()
Returns the return type represented by this instance.
|
TypeDescription |
JavaType.getTypeStub()
Returns at least a stub representing this type where the stub does not define any methods or fields.
|
static <T extends TypeDescription> |
ByteBuddyCommons.isInterface(T[] typeDescription)
Validates if an array of type only contains interfaces.
|
| Modifier and Type | Method and Description |
|---|---|
List<TypeDescription> |
JavaInstance.MethodType.getParameterTypes()
Returns the parameter types of this method type.
|
List<TypeDescription> |
JavaInstance.MethodHandle.getParameterTypes()
Returns the parameter types represented by this instance.
|
| Modifier and Type | Method and Description |
|---|---|
static <T extends TypeDescription> |
ByteBuddyCommons.isInterface(T[] typeDescription)
Validates if an array of type only contains interfaces.
|
static JavaInstance.MethodType |
JavaInstance.MethodType.of(TypeDescription returnType,
List<? extends TypeDescription> parameterTypes)
Returns a method type description of the given return type and parameter types.
|
static JavaInstance.MethodType |
JavaInstance.MethodType.ofConstant(TypeDescription typeDescription)
Returns a method type for the given constant type.
|
static JavaInstance.MethodHandle |
JavaInstance.MethodHandle.ofSpecial(MethodDescription methodDescription,
TypeDescription typeDescription)
Creates a method handle representation of the given method for an explicit special method invocation of an otherwise virtual method.
|
| Modifier and Type | Method and Description |
|---|---|
static JavaInstance.MethodType |
JavaInstance.MethodType.of(TypeDescription returnType,
List<? extends TypeDescription> parameterTypes)
Returns a method type description of the given return type and parameter types.
|
| Constructor and Description |
|---|
MethodHandle(JavaInstance.MethodHandle.HandleType handleType,
TypeDescription ownerType,
String name,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes)
Creates a method handle representation.
|
MethodType(TypeDescription returnType,
List<? extends TypeDescription> parameterTypes)
Creates a method type for the given types.
|
| Constructor and Description |
|---|
MethodHandle(JavaInstance.MethodHandle.HandleType handleType,
TypeDescription ownerType,
String name,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes)
Creates a method handle representation.
|
MethodType(TypeDescription returnType,
List<? extends TypeDescription> parameterTypes)
Creates a method type for the given types.
|
Copyright © 2014–2015. All rights reserved.