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.asm |
The ASM package contains classes that are meant for direct interaction with the ASM API.
|
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. fields, types and byte code methods.
|
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.collection |
This package is dedicated to creating
StackManipulation s
that create collections or arrays from a given number of values. |
net.bytebuddy.implementation.bytecode.constant |
StackManipulation s in this package are responsible for
creating compile-time constants and pushing them onto the operand stack. |
net.bytebuddy.implementation.bytecode.member |
StackManipulation s of this package are responsible for
accessing type or method members, i.e. reading and writing of fields, invoking of methods, access of local variables
within a method invocation or returning values from method invocations. |
net.bytebuddy.matcher |
Contains an API for matching Java byte code entities.
|
net.bytebuddy.pool |
Classes of this package allow for the creating
TypeDescription s without
loading any classes. |
net.bytebuddy.utility |
This package contains utility classes for common use within any Byte Buddy logic.
|
Modifier and Type | Method and Description |
---|---|
protected abstract String |
NamingStrategy.AbstractBase.name(TypeDescription superClass)
Determines a new name when creating a new type that subclasses the provided type.
|
protected String |
NamingStrategy.SuffixingRandom.name(TypeDescription superClass) |
protected String |
NamingStrategy.PrefixingRandom.name(TypeDescription superClass) |
static ClassFileVersion |
ClassFileVersion.of(TypeDescription typeDescription,
ClassFileLocator classFileLocator)
Extracts a class' class version.
|
String |
NamingStrategy.rebase(TypeDescription typeDescription)
Determines a name for the dynamic type when rebasing the provided type.
|
String |
NamingStrategy.AbstractBase.rebase(TypeDescription typeDescription) |
<T> DynamicType.Builder<T> |
ByteBuddy.rebase(TypeDescription type,
ClassFileLocator classFileLocator)
Rebases the given type where any intercepted method that is declared by the redefined type is preserved within the
rebased type's class such that the class's original can be invoked from the new method implementations.
|
<T> DynamicType.Builder<T> |
ByteBuddy.rebase(TypeDescription type,
ClassFileLocator classFileLocator,
MethodNameTransformer methodNameTransformer)
Rebases the given type where any intercepted method that is declared by the redefined type is preserved within the
rebased type's class such that the class's original can be invoked from the new method implementations.
|
String |
NamingStrategy.redefine(TypeDescription typeDescription)
Determines a name for the dynamic type when redefining the provided type.
|
String |
NamingStrategy.AbstractBase.redefine(TypeDescription typeDescription) |
<T> DynamicType.Builder<T> |
ByteBuddy.redefine(TypeDescription type,
ClassFileLocator classFileLocator)
Redefines the given type where any intercepted method that is declared by the redefined type is fully replaced
by the new implementation.
|
String |
NamingStrategy.SuffixingRandom.BaseNameResolver.resolve(TypeDescription typeDescription)
Resolves the base name for a given type description.
|
String |
NamingStrategy.SuffixingRandom.BaseNameResolver.ForUnnamedType.resolve(TypeDescription typeDescription) |
String |
NamingStrategy.SuffixingRandom.BaseNameResolver.ForGivenType.resolve(TypeDescription typeDescription) |
String |
NamingStrategy.SuffixingRandom.BaseNameResolver.ForFixedValue.resolve(TypeDescription typeDescription) |
Constructor and Description |
---|
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. |
Modifier and Type | Method and Description |
---|---|
TypeDescription |
AgentBuilder.DescriptionStrategy.apply(Class<?> type,
AgentBuilder.TypeLocator typeLocator,
AgentBuilder.LocationStrategy locationStrategy)
Describes the given type.
|
TypeDescription |
AgentBuilder.DescriptionStrategy.Default.apply(Class<?> type,
AgentBuilder.TypeLocator typeLocator,
AgentBuilder.LocationStrategy locationStrategy) |
TypeDescription |
AgentBuilder.DescriptionStrategy.apply(String typeName,
Class<?> type,
TypePool typePool)
Describes the given type.
|
Modifier and Type | Method and Description |
---|---|
DynamicType.Builder<?> |
AgentBuilder.TypeStrategy.builder(TypeDescription typeDescription,
ByteBuddy byteBuddy,
ClassFileLocator classFileLocator,
MethodNameTransformer methodNameTransformer)
Creates a type builder for a given type.
|
boolean |
AgentBuilder.RedefinitionStrategy.Collector.consider(TypeDescription typeDescription,
Class<?> type,
AgentBuilder.RawMatcher ignoredTypeMatcher)
Considers a loaded class for modification.
|
boolean |
AgentBuilder.RedefinitionStrategy.Collector.ForRedefinition.consider(TypeDescription typeDescription,
Class<?> type,
AgentBuilder.RawMatcher ignoredTypeMatcher) |
boolean |
AgentBuilder.RedefinitionStrategy.Collector.ForRetransformation.consider(TypeDescription typeDescription,
Class<?> type,
AgentBuilder.RawMatcher ignoredTypeMatcher) |
boolean |
AgentBuilder.Default.Transformation.isAlive(TypeDescription typeDescription,
ClassLoader classLoader,
JavaModule module,
Class<?> classBeingRedefined,
ProtectionDomain protectionDomain,
AgentBuilder.RawMatcher ignoredTypeMatcher)
Checks if this transformation is alive.
|
boolean |
AgentBuilder.Default.Transformation.Ignored.isAlive(TypeDescription typeDescription,
ClassLoader classLoader,
JavaModule module,
Class<?> classBeingRedefined,
ProtectionDomain protectionDomain,
AgentBuilder.RawMatcher ignoredTypeMatcher) |
boolean |
AgentBuilder.Default.Transformation.Simple.isAlive(TypeDescription typeDescription,
ClassLoader classLoader,
JavaModule module,
Class<?> classBeingRedefined,
ProtectionDomain protectionDomain,
AgentBuilder.RawMatcher ignoredTypeMatcher) |
boolean |
AgentBuilder.Default.Transformation.Compound.isAlive(TypeDescription typeDescription,
ClassLoader classLoader,
JavaModule module,
Class<?> classBeingRedefined,
ProtectionDomain protectionDomain,
AgentBuilder.RawMatcher ignoredTypeMatcher) |
boolean |
AgentBuilder.RawMatcher.matches(TypeDescription typeDescription,
ClassLoader classLoader,
JavaModule module,
Class<?> classBeingRedefined,
ProtectionDomain protectionDomain)
Decides if the given
typeDescription should be instrumented with the entailed
AgentBuilder.Transformer s. |
boolean |
AgentBuilder.RawMatcher.Conjunction.matches(TypeDescription typeDescription,
ClassLoader classLoader,
JavaModule module,
Class<?> classBeingRedefined,
ProtectionDomain protectionDomain) |
boolean |
AgentBuilder.RawMatcher.Disjunction.matches(TypeDescription typeDescription,
ClassLoader classLoader,
JavaModule module,
Class<?> classBeingRedefined,
ProtectionDomain protectionDomain) |
boolean |
AgentBuilder.RawMatcher.ForElementMatchers.matches(TypeDescription typeDescription,
ClassLoader classLoader,
JavaModule module,
Class<?> classBeingRedefined,
ProtectionDomain protectionDomain) |
void |
AgentBuilder.Listener.onIgnored(TypeDescription typeDescription,
ClassLoader classLoader,
JavaModule module)
Invoked when a type is not transformed but ignored.
|
void |
AgentBuilder.Listener.NoOp.onIgnored(TypeDescription typeDescription,
ClassLoader classLoader,
JavaModule module) |
void |
AgentBuilder.Listener.Adapter.onIgnored(TypeDescription typeDescription,
ClassLoader classLoader,
JavaModule module) |
void |
AgentBuilder.Listener.StreamWriting.onIgnored(TypeDescription typeDescription,
ClassLoader classLoader,
JavaModule module) |
void |
AgentBuilder.Listener.Compound.onIgnored(TypeDescription typeDescription,
ClassLoader classLoader,
JavaModule module) |
void |
AgentBuilder.Listener.onTransformation(TypeDescription typeDescription,
ClassLoader classLoader,
JavaModule module,
DynamicType dynamicType)
Invoked right before a successful transformation is applied.
|
void |
AgentBuilder.Listener.NoOp.onTransformation(TypeDescription typeDescription,
ClassLoader classLoader,
JavaModule module,
DynamicType dynamicType) |
void |
AgentBuilder.Listener.Adapter.onTransformation(TypeDescription typeDescription,
ClassLoader classLoader,
JavaModule module,
DynamicType dynamicType) |
void |
AgentBuilder.Listener.StreamWriting.onTransformation(TypeDescription typeDescription,
ClassLoader classLoader,
JavaModule module,
DynamicType dynamicType) |
void |
AgentBuilder.Listener.ModuleReadEdgeCompleting.onTransformation(TypeDescription typeDescription,
ClassLoader classLoader,
JavaModule module,
DynamicType dynamicType) |
void |
AgentBuilder.Listener.Compound.onTransformation(TypeDescription typeDescription,
ClassLoader classLoader,
JavaModule module,
DynamicType dynamicType) |
AgentBuilder.Default.Transformation.Resolution |
AgentBuilder.Default.Transformation.resolve(TypeDescription typeDescription,
ClassLoader classLoader,
JavaModule module,
Class<?> classBeingRedefined,
ProtectionDomain protectionDomain,
TypePool typePool,
AgentBuilder.RawMatcher ignoredTypeMatcher)
Resolves an attempted transformation to a specific transformation.
|
AgentBuilder.Default.Transformation.Resolution |
AgentBuilder.Default.Transformation.Ignored.resolve(TypeDescription typeDescription,
ClassLoader classLoader,
JavaModule module,
Class<?> classBeingRedefined,
ProtectionDomain protectionDomain,
TypePool typePool,
AgentBuilder.RawMatcher ignoredTypeMatcher) |
AgentBuilder.Default.Transformation.Resolution |
AgentBuilder.Default.Transformation.Simple.resolve(TypeDescription typeDescription,
ClassLoader classLoader,
JavaModule module,
Class<?> classBeingRedefined,
ProtectionDomain protectionDomain,
TypePool typePool,
AgentBuilder.RawMatcher ignoredTypeMatcher) |
AgentBuilder.Default.Transformation.Resolution |
AgentBuilder.Default.Transformation.Compound.resolve(TypeDescription typeDescription,
ClassLoader classLoader,
JavaModule module,
Class<?> classBeingRedefined,
ProtectionDomain protectionDomain,
TypePool typePool,
AgentBuilder.RawMatcher ignoredTypeMatcher) |
DynamicType.Builder<?> |
AgentBuilder.Transformer.transform(DynamicType.Builder<?> builder,
TypeDescription typeDescription,
ClassLoader classLoader)
Allows for a transformation of a
DynamicType.Builder . |
DynamicType.Builder<?> |
AgentBuilder.Transformer.NoOp.transform(DynamicType.Builder<?> builder,
TypeDescription typeDescription,
ClassLoader classLoader) |
DynamicType.Builder<?> |
AgentBuilder.Transformer.Compound.transform(DynamicType.Builder<?> builder,
TypeDescription typeDescription,
ClassLoader classLoader) |
MethodVisitor |
AgentBuilder.LambdaInstrumentationStrategy.MetaFactoryRedirection.wrap(TypeDescription instrumentedType,
MethodDescription.InDefinedShape methodDescription,
MethodVisitor methodVisitor,
ClassFileVersion classFileVersion,
int writerFlags,
int readerFlags) |
MethodVisitor |
AgentBuilder.LambdaInstrumentationStrategy.AlternativeMetaFactoryRedirection.wrap(TypeDescription instrumentedType,
MethodDescription.InDefinedShape methodDescription,
MethodVisitor methodVisitor,
ClassFileVersion classFileVersion,
int writerFlags,
int readerFlags) |
Modifier and Type | Method and Description |
---|---|
T |
AgentBuilder.Matchable.and(ElementMatcher<? super TypeDescription> typeMatcher)
Defines a matching that is positive if both the previous matcher and the supplied matcher are matched.
|
S |
AgentBuilder.Matchable.AbstractBase.and(ElementMatcher<? super TypeDescription> typeMatcher) |
T |
AgentBuilder.Matchable.and(ElementMatcher<? super TypeDescription> typeMatcher,
ElementMatcher<? super ClassLoader> classLoaderMatcher)
Defines a matching that is positive if both the previous matcher and the supplied matcher are matched.
|
S |
AgentBuilder.Matchable.AbstractBase.and(ElementMatcher<? super TypeDescription> typeMatcher,
ElementMatcher<? super ClassLoader> classLoaderMatcher) |
T |
AgentBuilder.Matchable.and(ElementMatcher<? super TypeDescription> typeMatcher,
ElementMatcher<? super ClassLoader> classLoaderMatcher,
ElementMatcher<? super JavaModule> moduleMatcher)
Defines a matching that is positive if both the previous matcher and the supplied matcher are matched.
|
S |
AgentBuilder.Matchable.AbstractBase.and(ElementMatcher<? super TypeDescription> typeMatcher,
ElementMatcher<? super ClassLoader> classLoaderMatcher,
ElementMatcher<? super JavaModule> moduleMatcher) |
AgentBuilder.Ignored |
AgentBuilder.ignore(ElementMatcher<? super TypeDescription> typeMatcher)
Excludes any type that is matched by the provided matcher from instrumentation and considers types by all
ClassLoader s. |
AgentBuilder.Ignored |
AgentBuilder.Default.ignore(ElementMatcher<? super TypeDescription> typeMatcher) |
AgentBuilder.Ignored |
AgentBuilder.Default.Delegator.ignore(ElementMatcher<? super TypeDescription> ignoredTypes) |
AgentBuilder.Ignored |
AgentBuilder.ignore(ElementMatcher<? super TypeDescription> typeMatcher,
ElementMatcher<? super ClassLoader> classLoaderMatcher)
Excludes any type that is matched by the provided matcher and is loaded by a class loader matching the second matcher.
|
AgentBuilder.Ignored |
AgentBuilder.Default.ignore(ElementMatcher<? super TypeDescription> typeMatcher,
ElementMatcher<? super ClassLoader> classLoaderMatcher) |
AgentBuilder.Ignored |
AgentBuilder.Default.Delegator.ignore(ElementMatcher<? super TypeDescription> ignoredTypes,
ElementMatcher<? super ClassLoader> ignoredClassLoaders) |
AgentBuilder.Ignored |
AgentBuilder.ignore(ElementMatcher<? super TypeDescription> typeMatcher,
ElementMatcher<? super ClassLoader> classLoaderMatcher,
ElementMatcher<? super JavaModule> moduleMatcher)
Excludes any type that is matched by the provided matcher and is loaded by a class loader matching the second matcher.
|
AgentBuilder.Ignored |
AgentBuilder.Default.ignore(ElementMatcher<? super TypeDescription> typeMatcher,
ElementMatcher<? super ClassLoader> classLoaderMatcher,
ElementMatcher<? super JavaModule> moduleMatcher) |
AgentBuilder.Ignored |
AgentBuilder.Default.Delegator.ignore(ElementMatcher<? super TypeDescription> typeMatcher,
ElementMatcher<? super ClassLoader> classLoaderMatcher,
ElementMatcher<? super JavaModule> moduleMatcher) |
T |
AgentBuilder.Matchable.or(ElementMatcher<? super TypeDescription> typeMatcher)
Defines a matching that is positive if the previous matcher or the supplied matcher are matched.
|
S |
AgentBuilder.Matchable.AbstractBase.or(ElementMatcher<? super TypeDescription> typeMatcher) |
T |
AgentBuilder.Matchable.or(ElementMatcher<? super TypeDescription> typeMatcher,
ElementMatcher<? super ClassLoader> classLoaderMatcher)
Defines a matching that is positive if the previous matcher or the supplied matcher are matched.
|
S |
AgentBuilder.Matchable.AbstractBase.or(ElementMatcher<? super TypeDescription> typeMatcher,
ElementMatcher<? super ClassLoader> classLoaderMatcher) |
T |
AgentBuilder.Matchable.or(ElementMatcher<? super TypeDescription> typeMatcher,
ElementMatcher<? super ClassLoader> classLoaderMatcher,
ElementMatcher<? super JavaModule> moduleMatcher)
Defines a matching that is positive if the previous matcher or the supplied matcher are matched.
|
S |
AgentBuilder.Matchable.AbstractBase.or(ElementMatcher<? super TypeDescription> typeMatcher,
ElementMatcher<? super ClassLoader> classLoaderMatcher,
ElementMatcher<? super JavaModule> moduleMatcher) |
AgentBuilder.Identified.Narrowable |
AgentBuilder.type(ElementMatcher<? super TypeDescription> typeMatcher)
Matches a type being loaded in order to apply the supplied
AgentBuilder.Transformer s before loading this type. |
AgentBuilder.Identified.Narrowable |
AgentBuilder.Default.type(ElementMatcher<? super TypeDescription> typeMatcher) |
AgentBuilder.Identified.Narrowable |
AgentBuilder.Default.Delegator.type(ElementMatcher<? super TypeDescription> typeMatcher) |
AgentBuilder.Identified.Narrowable |
AgentBuilder.type(ElementMatcher<? super TypeDescription> typeMatcher,
ElementMatcher<? super ClassLoader> classLoaderMatcher)
Matches a type being loaded in order to apply the supplied
AgentBuilder.Transformer s before loading this type. |
AgentBuilder.Identified.Narrowable |
AgentBuilder.Default.type(ElementMatcher<? super TypeDescription> typeMatcher,
ElementMatcher<? super ClassLoader> classLoaderMatcher) |
AgentBuilder.Identified.Narrowable |
AgentBuilder.Default.Delegator.type(ElementMatcher<? super TypeDescription> typeMatcher,
ElementMatcher<? super ClassLoader> classLoaderMatcher) |
AgentBuilder.Identified.Narrowable |
AgentBuilder.type(ElementMatcher<? super TypeDescription> typeMatcher,
ElementMatcher<? super ClassLoader> classLoaderMatcher,
ElementMatcher<? super JavaModule> moduleMatcher)
Matches a type being loaded in order to apply the supplied
AgentBuilder.Transformer s before loading this type. |
AgentBuilder.Identified.Narrowable |
AgentBuilder.Default.type(ElementMatcher<? super TypeDescription> typeMatcher,
ElementMatcher<? super ClassLoader> classLoaderMatcher,
ElementMatcher<? super JavaModule> moduleMatcher) |
AgentBuilder.Identified.Narrowable |
AgentBuilder.Default.Delegator.type(ElementMatcher<? super TypeDescription> typeMatcher,
ElementMatcher<? super ClassLoader> classLoaderMatcher,
ElementMatcher<? super JavaModule> moduleMatcher) |
Constructor and Description |
---|
Appender(TypeDescription instrumentedType)
Creates a new appender.
|
InjectingInitializer(TypeDescription instrumentedType,
Map<TypeDescription,byte[]> rawAuxiliaryTypes,
Map<TypeDescription,LoadedTypeInitializer> loadedTypeInitializers,
ClassInjector classInjector)
Creates a new injection initializer.
|
Resolution(TypeDescription typeDescription,
ClassLoader classLoader,
JavaModule module,
ProtectionDomain protectionDomain,
TypePool typePool,
AgentBuilder.Transformer transformer,
boolean decorator)
Creates a new active transformation.
|
SerializationImplementation(TypeDescription targetType,
TypeDescription lambdaType,
String lambdaMethodName,
JavaConstant.MethodType lambdaMethod,
JavaConstant.MethodHandle targetMethod,
JavaConstant.MethodType specializedMethod)
Creates a new implementation for a serializable's lambda expression's
writeReplace method. |
Unresolved(TypeDescription typeDescription,
ClassLoader classLoader,
JavaModule module)
Creates a new unresolved resolution.
|
Constructor and Description |
---|
ForElementMatchers(ElementMatcher<? super TypeDescription> typeMatcher,
ElementMatcher<? super ClassLoader> classLoaderMatcher,
ElementMatcher<? super JavaModule> moduleMatcher)
Creates a new
AgentBuilder.RawMatcher that only matches the
supplied TypeDescription and its ClassLoader against two matcher in order
to decided if an instrumentation should be conducted. |
InjectingInitializer(TypeDescription instrumentedType,
Map<TypeDescription,byte[]> rawAuxiliaryTypes,
Map<TypeDescription,LoadedTypeInitializer> loadedTypeInitializers,
ClassInjector classInjector)
Creates a new injection initializer.
|
InjectingInitializer(TypeDescription instrumentedType,
Map<TypeDescription,byte[]> rawAuxiliaryTypes,
Map<TypeDescription,LoadedTypeInitializer> loadedTypeInitializers,
ClassInjector classInjector)
Creates a new injection initializer.
|
Modifier and Type | Field and Description |
---|---|
protected TypeDescription |
Advice.Dispatcher.OffsetMapping.ForField.targetType
The expected type that the field can be assigned to.
|
Modifier and Type | Method and Description |
---|---|
TypeDescription |
Advice.Dispatcher.Resolved.ForMethodEnter.getEnterType()
Returns the type that this dispatcher supplies as a result of its advice or a description of
void if
no type is supplied as a result of the enter advice. |
TypeDescription |
Advice.Dispatcher.Inactive.getEnterType() |
TypeDescription |
Advice.Dispatcher.Inlining.Resolved.ForMethodEnter.getEnterType() |
TypeDescription |
Advice.Dispatcher.Delegating.Resolved.ForMethodEnter.getEnterType() |
TypeDescription |
Advice.Dispatcher.Resolved.ForMethodExit.getTriggeringThrowable()
Returns the type of throwable for which this exit advice is supposed to be invoked.
|
TypeDescription |
Advice.Dispatcher.Inactive.getTriggeringThrowable() |
TypeDescription |
Advice.Dispatcher.Inlining.Resolved.ForMethodExit.WithExceptionHandler.getTriggeringThrowable() |
TypeDescription |
Advice.Dispatcher.Inlining.Resolved.ForMethodExit.WithoutExceptionHandler.getTriggeringThrowable() |
TypeDescription |
Advice.Dispatcher.Delegating.Resolved.ForMethodExit.WithExceptionHandler.getTriggeringThrowable() |
TypeDescription |
Advice.Dispatcher.Delegating.Resolved.ForMethodExit.WithoutExceptionHandler.getTriggeringThrowable() |
Modifier and Type | Method and Description |
---|---|
protected Advice.Dispatcher.OffsetMapping.Target |
Advice.Dispatcher.OffsetMapping.Target.ForParameter.ReadWrite.casted(TypeDescription targetType)
Resolves a parameter mapping where the value is casted to the given type prior to assignment.
|
protected abstract FieldLocator |
Advice.Dispatcher.OffsetMapping.ForField.fieldLocator(TypeDescription instrumentedType)
Returns a field locator for this instance.
|
protected FieldLocator |
Advice.Dispatcher.OffsetMapping.ForField.WithImplicitType.fieldLocator(TypeDescription instrumentedType) |
protected FieldLocator |
Advice.Dispatcher.OffsetMapping.ForField.WithExplicitType.fieldLocator(TypeDescription instrumentedType) |
protected static Advice.Dispatcher.Resolved.ForMethodExit |
Advice.Dispatcher.Inlining.Resolved.ForMethodExit.of(MethodDescription.InDefinedShape adviceMethod,
List<? extends Advice.Dispatcher.OffsetMapping.Factory> userFactories,
ClassReader classReader,
TypeDescription enterType)
Resolves exit advice that handles exceptions depending on the specification of the exit advice.
|
protected static Advice.Dispatcher.Resolved.ForMethodExit |
Advice.Dispatcher.Delegating.Resolved.ForMethodExit.of(MethodDescription.InDefinedShape adviceMethod,
List<? extends Advice.Dispatcher.OffsetMapping.Factory> userFactories,
TypeDescription enterType)
Resolves exit advice that handles exceptions depending on the specification of the exit advice.
|
protected static Advice.Dispatcher.OffsetMapping.Context |
Advice.Dispatcher.OffsetMapping.Context.ForMethodExit.of(TypeDescription typeDescription)
Resolves an appropriate method exit context for the supplied entry method type.
|
protected static Advice.Dispatcher.SuppressionHandler |
Advice.Dispatcher.SuppressionHandler.Suppressing.of(TypeDescription suppressedType)
Resolves an appropriate suppression handler.
|
protected static Advice.Dispatcher.OffsetMapping.Target |
Advice.Dispatcher.OffsetMapping.Target.ForSerializedObject.of(TypeDescription target,
Serializable value)
Resolves a serializable value to a target that reads a value from reconstructing a serializable string representation.
|
static Advice |
Advice.to(TypeDescription advice)
Implements advice where every matched method is advised by the given type's advisory methods.
|
static Advice |
Advice.to(TypeDescription advice,
ClassFileLocator classFileLocator)
Implements advice where every matched method is advised by the given type's advisory methods.
|
Advice |
Advice.WithCustomMapping.to(TypeDescription advice,
ClassFileLocator classFileLocator)
Implements advice where every matched method is advised by the given type's advisory methods.
|
protected static Advice |
Advice.to(TypeDescription advice,
ClassFileLocator classFileLocator,
List<? extends Advice.Dispatcher.OffsetMapping.Factory> userFactories)
Creates a new advice.
|
static Advice |
Advice.to(TypeDescription enterAdvice,
TypeDescription exitAdvice)
Implements advice where every matched method is advised by the given type's advisory methods.
|
Advice |
Advice.WithCustomMapping.to(TypeDescription enterAdvice,
TypeDescription exitAdvice)
Implements advice where every matched method is advised by the given type's advisory methods.
|
static Advice |
Advice.to(TypeDescription enterAdvice,
TypeDescription exitAdvice,
ClassFileLocator classFileLocator)
Implements advice where every matched method is advised by the given type's advisory methods.
|
Advice |
Advice.WithCustomMapping.to(TypeDescription enterAdvice,
TypeDescription exitAdvice,
ClassFileLocator classFileLocator)
Implements advice where every matched method is advised by the given type's advisory methods.
|
protected static Advice |
Advice.to(TypeDescription enterAdvice,
TypeDescription exitAdvice,
ClassFileLocator classFileLocator,
List<? extends Advice.Dispatcher.OffsetMapping.Factory> userFactories)
Creates a new advice.
|
protected static Object |
Advice.StackMapFrameHandler.Default.toFrame(TypeDescription typeDescription)
Translates a type into a representation of its form inside a stack map frame.
|
ClassVisitor |
TypeConstantAdjustment.wrap(TypeDescription instrumentedType,
ClassVisitor classVisitor,
int writerFlags,
int readerFlags) |
ClassVisitor |
AsmVisitorWrapper.wrap(TypeDescription instrumentedType,
ClassVisitor classVisitor,
int writerFlags,
int readerFlags)
Applies a
ClassVisitorWrapper to the creation of a DynamicType . |
ClassVisitor |
AsmVisitorWrapper.NoOp.wrap(TypeDescription instrumentedType,
ClassVisitor classVisitor,
int writerFlags,
int readerFlags) |
ClassVisitor |
AsmVisitorWrapper.ForDeclaredFields.wrap(TypeDescription instrumentedType,
ClassVisitor classVisitor,
int writerFlags,
int readerFlags) |
ClassVisitor |
AsmVisitorWrapper.ForDeclaredMethods.wrap(TypeDescription instrumentedType,
ClassVisitor classVisitor,
int writerFlags,
int readerFlags) |
ClassVisitor |
AsmVisitorWrapper.Compound.wrap(TypeDescription instrumentedType,
ClassVisitor classVisitor,
int writerFlags,
int readerFlags) |
FieldVisitor |
AsmVisitorWrapper.ForDeclaredFields.FieldVisitorWrapper.wrap(TypeDescription instrumentedType,
FieldDescription.InDefinedShape fieldDescription,
FieldVisitor fieldVisitor)
Wraps a field visitor.
|
FieldVisitor |
AsmVisitorWrapper.ForDeclaredFields.Entry.wrap(TypeDescription instrumentedType,
FieldDescription.InDefinedShape fieldDescription,
FieldVisitor fieldVisitor) |
MethodVisitor |
AsmVisitorWrapper.ForDeclaredMethods.MethodVisitorWrapper.wrap(TypeDescription instrumentedType,
MethodDescription.InDefinedShape methodDescription,
MethodVisitor methodVisitor,
ClassFileVersion classFileVersion,
int writerFlags,
int readerFlags)
Wraps a method visitor.
|
MethodVisitor |
AsmVisitorWrapper.ForDeclaredMethods.Entry.wrap(TypeDescription instrumentedType,
MethodDescription.InDefinedShape methodDescription,
MethodVisitor methodVisitor,
ClassFileVersion classFileVersion,
int writerFlags,
int readerFlags) |
MethodVisitor |
Advice.wrap(TypeDescription instrumentedType,
MethodDescription.InDefinedShape methodDescription,
MethodVisitor methodVisitor,
ClassFileVersion classFileVersion,
int writerFlags,
int readerFlags) |
Modifier and Type | Method and Description |
---|---|
protected void |
Advice.StackMapFrameHandler.Default.injectFullFrame(MethodVisitor methodVisitor,
List<? extends TypeDescription> typesInArray,
List<? extends TypeDescription> typesOnStack)
Injects a full stack map frame.
|
protected void |
Advice.StackMapFrameHandler.Default.injectFullFrame(MethodVisitor methodVisitor,
List<? extends TypeDescription> typesInArray,
List<? extends TypeDescription> typesOnStack)
Injects a full stack map frame.
|
protected static Advice.StackMapFrameHandler.ForInstrumentedMethod |
Advice.StackMapFrameHandler.Default.of(MethodDescription.InDefinedShape instrumentedMethod,
List<? extends TypeDescription> requiredTypes,
List<? extends TypeDescription> yieldedTypes,
ClassFileVersion classFileVersion,
int writerFlags,
int readerFlags)
Creates an appropriate stack map frame handler for an instrumented method.
|
protected static Advice.StackMapFrameHandler.ForInstrumentedMethod |
Advice.StackMapFrameHandler.Default.of(MethodDescription.InDefinedShape instrumentedMethod,
List<? extends TypeDescription> requiredTypes,
List<? extends TypeDescription> yieldedTypes,
ClassFileVersion classFileVersion,
int writerFlags,
int readerFlags)
Creates an appropriate stack map frame handler for an instrumented method.
|
protected static Advice.MethodSizeHandler.ForInstrumentedMethod |
Advice.MethodSizeHandler.Default.of(MethodDescription.InDefinedShape instrumentedMethod,
List<? extends TypeDescription> requiredTypes,
List<? extends TypeDescription> yieldedTypes,
int writerFlags)
Creates a method size handler applicable for the given instrumented method.
|
protected static Advice.MethodSizeHandler.ForInstrumentedMethod |
Advice.MethodSizeHandler.Default.of(MethodDescription.InDefinedShape instrumentedMethod,
List<? extends TypeDescription> requiredTypes,
List<? extends TypeDescription> yieldedTypes,
int writerFlags)
Creates a method size handler applicable for the given instrumented method.
|
Constructor and Description |
---|
Bound(TypeDescription suppressedType)
Creates a new active, bound suppression handler.
|
DispatchingVisitor(ClassVisitor classVisitor,
TypeDescription instrumentedType)
Creates a new dispatching visitor.
|
DispatchingVisitor(ClassVisitor classVisitor,
TypeDescription instrumentedType,
int writerFlags,
int readerFlags)
Creates a new dispatching visitor.
|
Factory(TypeDescription enterType,
boolean readOnly)
Creates a new factory for creating a
Advice.Dispatcher.OffsetMapping.ForEnterValue offset mapping. |
Factory(TypeDescription triggeringThrowable,
boolean readOnly)
Creates a new factory for access of the exception that is thrown by the instrumented method..
|
ForField(String name,
TypeDescription targetType,
boolean readOnly)
Creates an offset mapping for a field.
|
ForMethodExit(MethodDescription.InDefinedShape adviceMethod,
List<? extends Advice.Dispatcher.OffsetMapping.Factory> userFactories,
ClassReader classReader,
TypeDescription enterType)
Creates a new resolved dispatcher for implementing method exit advice.
|
ForMethodExit(MethodDescription.InDefinedShape adviceMethod,
List<? extends Advice.Dispatcher.OffsetMapping.Factory> userFactories,
TypeDescription enterType)
Creates a new resolved dispatcher for implementing method exit advice.
|
ForParameter(Advice.Argument argument,
TypeDescription targetType)
Creates a new offset mapping for a parameter.
|
ForParameter(int index,
boolean readOnly,
TypeDescription targetType)
Creates a new offset mapping for a parameter of the instrumented method.
|
ForReturnValue(boolean readOnly,
TypeDescription targetType)
Creates an offset mapping for accessing the return type of the instrumented method.
|
ForSerializedObject(TypeDescription target,
String serialized)
Creates a target for an offset mapping that references a serialized value.
|
ForThisReference(boolean readOnly,
boolean optional,
TypeDescription targetType)
Creates a new offset mapping for a
this reference. |
ForThrowable(TypeDescription targetType,
TypeDescription triggeringThrowable,
boolean readOnly)
Creates a new offset mapping for access of the exception that is thrown by the instrumented method..
|
Resolved(MethodDescription.InDefinedShape adviceMethod,
List<Advice.Dispatcher.OffsetMapping.Factory> factories,
ClassReader classReader,
TypeDescription throwableType)
Creates a new resolved version of a dispatcher.
|
Resolved(MethodDescription.InDefinedShape adviceMethod,
List<Advice.Dispatcher.OffsetMapping.Factory> factories,
TypeDescription throwableType)
Creates a new resolved version of a dispatcher.
|
Suppressing(TypeDescription suppressedType)
Creates a new suppressing suppression handler.
|
WithCasting(int offset,
TypeDescription targetType)
Creates a new parameter mapping with casting prior to assignment.
|
WithExceptionHandler(MethodDescription.InDefinedShape adviceMethod,
List<? extends Advice.Dispatcher.OffsetMapping.Factory> userFactories,
ClassReader classReader,
TypeDescription enterType,
TypeDescription triggeringThrowable)
Creates a new resolved dispatcher for implementing method exit advice that handles exceptions.
|
WithExceptionHandler(MethodDescription.InDefinedShape adviceMethod,
List<? extends Advice.Dispatcher.OffsetMapping.Factory> userFactories,
TypeDescription enterType,
TypeDescription triggeringThrowable)
Creates a new resolved dispatcher for implementing method exit advice that handles exceptions.
|
WithExceptionHandling(MethodVisitor methodVisitor,
MethodDescription.InDefinedShape instrumentedMethod,
Advice.Dispatcher.Resolved.ForMethodEnter methodEnter,
Advice.Dispatcher.Resolved.ForMethodExit methodExit,
ClassFileVersion classFileVersion,
int writerFlags,
int readerFlags,
TypeDescription triggeringThrowable)
Creates a new advice visitor that captures exception by weaving try-catch blocks around user code.
|
WithExplicitType(String name,
TypeDescription targetType,
TypeDescription locatedType,
boolean readOnly)
Creates an offset mapping for a field with an explicit declaring type.
|
WithImplicitType(String name,
TypeDescription targetType,
boolean readOnly)
Creates an offset mapping for a field with an implicit declaring type.
|
WithoutExceptionHandler(MethodDescription.InDefinedShape adviceMethod,
List<? extends Advice.Dispatcher.OffsetMapping.Factory> userFactories,
ClassReader classReader,
TypeDescription enterType)
Creates a new resolved dispatcher for implementing method exit advice that does not handle exceptions.
|
WithoutExceptionHandler(MethodDescription.InDefinedShape adviceMethod,
List<? extends Advice.Dispatcher.OffsetMapping.Factory> userFactories,
TypeDescription enterType)
Creates a new resolved dispatcher for implementing method exit advice that does not handle exceptions.
|
Constructor and Description |
---|
AdviceVisitor(MethodVisitor methodVisitor,
MethodVisitor delegate,
MethodDescription.InDefinedShape instrumentedMethod,
Advice.Dispatcher.Resolved.ForMethodEnter methodEnter,
Advice.Dispatcher.Resolved.ForMethodExit methodExit,
List<? extends TypeDescription> yieldedTypes,
ClassFileVersion classFileVersion,
int writerFlags,
int readerFlags)
Creates a new advice visitor.
|
WithExitAdvice(MethodVisitor methodVisitor,
MethodDescription.InDefinedShape instrumentedMethod,
Advice.Dispatcher.Resolved.ForMethodEnter methodEnter,
Advice.Dispatcher.Resolved.ForMethodExit methodExit,
List<? extends TypeDescription> yieldedTypes,
ClassFileVersion classFileVersion,
int writerFlags,
int readerFlags)
Creates an advice visitor that applies exit advice.
|
Modifier and Type | Method and Description |
---|---|
boolean |
ByteCodeElement.isVisibleTo(TypeDescription typeDescription)
Checks if this element is visible from a given type.
|
T |
TypeVariableSource.Visitor.onType(TypeDescription typeDescription)
Applies the visitor on a type.
|
TypeVariableSource |
TypeVariableSource.Visitor.NoOp.onType(TypeDescription typeDescription) |
Modifier and Type | Method and Description |
---|---|
S |
ByteCodeElement.TypeDependant.asToken(ElementMatcher<? super TypeDescription> matcher)
Returns a token representative of this type dependant.
|
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 . |
boolean |
AnnotationList.isAnnotationPresent(TypeDescription annotationType)
Checks if this list contains an annotation of the given type.
|
boolean |
AnnotationList.AbstractBase.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.
|
AnnotationDescription |
AnnotationList.ofType(TypeDescription annotationType)
Finds the first annotation of the given type and returns it.
|
AnnotationDescription |
AnnotationList.AbstractBase.ofType(TypeDescription annotationType) |
AnnotationDescription |
AnnotationList.Empty.ofType(TypeDescription annotationType) |
static AnnotationDescription.Builder |
AnnotationDescription.Builder.ofType(TypeDescription annotationType)
Creates a builder for creating an annotation of the given type.
|
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.AbstractBase.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.InDefinedShape.getDeclaringType() |
TypeDescription |
FieldDescription.ForLoadedField.getDeclaringType() |
TypeDescription |
FieldDescription.Latent.getDeclaringType() |
TypeDescription |
FieldDescription.SignatureToken.getType()
Returns the type of the represented field.
|
Modifier and Type | Method and Description |
---|---|
FieldDescription.SignatureToken |
FieldDescription.Token.asSignatureToken(TypeDescription declaringType)
Creates a signature token that represents the method that is represented by this token.
|
boolean |
FieldDescription.AbstractBase.isVisibleTo(TypeDescription typeDescription) |
Modifier and Type | Method and Description |
---|---|
FieldDescription.Token |
FieldDescription.AbstractBase.asToken(ElementMatcher<? super TypeDescription> matcher) |
ByteCodeElement.Token.TokenList<FieldDescription.Token> |
FieldList.asTokenList(ElementMatcher<? super TypeDescription> matcher)
Transforms the list of field descriptions into a list of detached tokens.
|
ByteCodeElement.Token.TokenList<FieldDescription.Token> |
FieldList.AbstractBase.asTokenList(ElementMatcher<? super TypeDescription> matcher) |
ByteCodeElement.Token.TokenList<FieldDescription.Token> |
FieldList.Empty.asTokenList(ElementMatcher<? super TypeDescription> matcher) |
Constructor and Description |
---|
ForTokens(TypeDescription declaringType,
FieldDescription.Token... token)
Creates a new field list from a list of field tokens.
|
ForTokens(TypeDescription declaringType,
List<? extends FieldDescription.Token> tokens)
Creates a new field list from a list of field tokens.
|
Latent(TypeDescription declaringType,
FieldDescription.Token token)
Creates a new latent field description.
|
Latent(TypeDescription declaringType,
String fieldName,
int modifiers,
TypeDescription.Generic fieldType,
List<? extends AnnotationDescription> declaredAnnotations)
Creates a new latent field description.
|
SignatureToken(String name,
TypeDescription type)
Creates a new signature token.
|
Modifier and Type | Method and Description |
---|---|
TypeDescription |
MethodDescription.InDefinedShape.getDeclaringType() |
TypeDescription |
MethodDescription.ForLoadedConstructor.getDeclaringType() |
TypeDescription |
MethodDescription.ForLoadedMethod.getDeclaringType() |
TypeDescription |
MethodDescription.Latent.getDeclaringType() |
TypeDescription |
MethodDescription.Latent.TypeInitializer.getDeclaringType() |
TypeDescription |
MethodDescription.SignatureToken.getReturnType()
Returns this token's return type.
|
TypeDescription |
MethodDescription.TypeToken.getReturnType()
Returns this token's return type.
|
Modifier and Type | Method and Description |
---|---|
List<TypeDescription> |
MethodDescription.SignatureToken.getParameterTypes()
Returns this token's parameter types.
|
List<TypeDescription> |
MethodDescription.TypeToken.getParameterTypes()
Returns this token's parameter types.
|
Modifier and Type | Method and Description |
---|---|
MethodDescription.SignatureToken |
MethodDescription.Token.asSignatureToken(TypeDescription declaringType)
Creates a signature token that represents the method that is represented by this token.
|
boolean |
MethodDescription.isInvokableOn(TypeDescription typeDescription)
Asserts if this method is invokable on an instance of the given type, i.e. the method is an instance method or
a constructor and the method is visible to the type and can be invoked on the given instance.
|
boolean |
MethodDescription.AbstractBase.isInvokableOn(TypeDescription typeDescription) |
boolean |
MethodDescription.isSpecializableFor(TypeDescription typeDescription)
Checks if this method can be called using the
INVOKESPECIAL for a given type. |
boolean |
MethodDescription.AbstractBase.isSpecializableFor(TypeDescription targetType) |
boolean |
MethodDescription.AbstractBase.isVisibleTo(TypeDescription typeDescription) |
Constructor and Description |
---|
ForTokens(TypeDescription declaringType,
List<? extends MethodDescription.Token> tokens)
Creates a new list of method descriptions for a list of detached tokens.
|
ForTokens(TypeDescription declaringType,
MethodDescription.Token... token)
Creates a new list of method descriptions for a list of detached tokens.
|
Latent(TypeDescription declaringType,
MethodDescription.Token token)
Creates a new latent method description.
|
Latent(TypeDescription declaringType,
String internalName,
int modifiers,
List<? extends TypeVariableToken> typeVariables,
TypeDescription.Generic returnType,
List<? extends ParameterDescription.Token> parameterTokens,
List<? extends TypeDescription.Generic> exceptionTypes,
List<? extends AnnotationDescription> declaredAnnotations,
Object defaultValue,
TypeDescription.Generic receiverType)
Creates a new latent method description.
|
SignatureToken(String name,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes)
Creates a new type token.
|
TypeInitializer(TypeDescription typeDescription)
Creates a new method description representing the type initializer.
|
TypeToken(TypeDescription returnType,
List<? extends TypeDescription> parameterTypes)
Creates a new type token.
|
Constructor and Description |
---|
SignatureToken(String name,
TypeDescription returnType,
List<? extends TypeDescription> parameterTypes)
Creates a new type token.
|
TypeToken(TypeDescription returnType,
List<? extends TypeDescription> parameterTypes)
Creates a new type token.
|
Modifier and Type | Class and Description |
---|---|
static class |
TypeDescription.AbstractBase
An abstract base implementation of a type description.
|
static class |
TypeDescription.AbstractBase.OfSimpleType
An adapter implementation of a
TypeDescription that
describes any type that is not an array or a primitive type. |
static class |
TypeDescription.AbstractBase.OfSimpleType.WithDelegation
An implementation of a type description that delegates all properties but the type's name to a delegate.
|
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.ForLoadedType.WithEagerProperties
A type description of a loaded type that resolves any field, constructor or method property eagerly, i.e. calls all of
Class.getDeclaredFields() , Class.getDeclaredMethods() , Class.getDeclaredConstructors() and
Class.getDeclaredClasses() . |
static class |
TypeDescription.ForPackageDescription
A type representation of a package description.
|
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.OBJECT
A representation of the
Object type. |
static TypeDescription |
TypeDescription.STRING
A representation of the
String type. |
static TypeDescription |
TypeDescription.THROWABLE
A representation of the
Throwable type. |
static TypeDescription |
TypeDescription.UNDEFINED
Represents any undefined property representing a type description that is instead represented as
null in order
to resemble the Java reflection API which returns null and is intuitive to many Java developers. |
static TypeDescription |
TypeDescription.VOID
A representation of the
void non-type. |
Modifier and Type | Method and Description |
---|---|
TypeDescription |
TypeDescription.Generic.OfNonGenericType.ForLoadedType.asErasure() |
TypeDescription |
TypeDescription.Generic.OfNonGenericType.Latent.asErasure() |
TypeDescription |
TypeDescription.Generic.OfNonGenericType.OfErasure.asErasure() |
TypeDescription |
TypeDescription.Generic.OfGenericArray.asErasure() |
TypeDescription |
TypeDescription.Generic.OfWildcardType.asErasure() |
TypeDescription |
TypeDescription.Generic.OfParameterizedType.ForLoadedType.asErasure() |
TypeDescription |
TypeDescription.Generic.OfParameterizedType.Latent.asErasure() |
TypeDescription |
TypeDescription.Generic.OfParameterizedType.ForGenerifiedErasure.asErasure() |
TypeDescription |
TypeDescription.Generic.OfTypeVariable.asErasure() |
TypeDescription |
TypeDescription.Generic.OfTypeVariable.Symbolic.asErasure() |
TypeDescription |
TypeDescription.Generic.LazyProjection.ForLoadedSuperClass.asErasure() |
TypeDescription |
TypeDescription.Generic.LazyProjection.ForLoadedFieldType.asErasure() |
TypeDescription |
TypeDescription.Generic.LazyProjection.ForLoadedReturnType.asErasure() |
TypeDescription |
TypeDescription.Generic.LazyProjection.OfConstructorParameter.asErasure() |
TypeDescription |
TypeDescription.Generic.LazyProjection.OfMethodParameter.asErasure() |
TypeDescription |
TypeDescription.AbstractBase.asErasure() |
TypeDescription |
TypeDefinition.asErasure()
Returns the erasure of this type.
|
protected abstract TypeDescription |
TypeDescription.AbstractBase.OfSimpleType.WithDelegation.delegate()
Returns the delegate type description to this type instance.
|
TypeDescription |
TypeList.ForLoadedTypes.get(int index) |
TypeDescription |
TypeList.Explicit.get(int index) |
TypeDescription |
TypeDescription.getComponentType() |
TypeDescription |
TypeDescription.AbstractBase.OfSimpleType.getComponentType() |
TypeDescription |
TypeDescription.ForLoadedType.getComponentType() |
TypeDescription |
TypeDescription.ArrayProjection.getComponentType() |
TypeDescription |
TypeDescription.getDeclaringType() |
TypeDescription |
TypeDescription.AbstractBase.OfSimpleType.WithDelegation.getDeclaringType() |
TypeDescription |
TypeDescription.ForLoadedType.getDeclaringType() |
TypeDescription |
TypeDescription.ArrayProjection.getDeclaringType() |
TypeDescription |
TypeDescription.Latent.getDeclaringType() |
TypeDescription |
TypeDescription.ForPackageDescription.getDeclaringType() |
TypeDescription |
TypeDescription.getEnclosingType()
Returns a description of this type's enclosing type if any.
|
TypeDescription |
TypeDescription.AbstractBase.OfSimpleType.WithDelegation.getEnclosingType() |
TypeDescription |
TypeDescription.ForLoadedType.getEnclosingType() |
TypeDescription |
TypeDescription.ArrayProjection.getEnclosingType() |
TypeDescription |
TypeDescription.Latent.getEnclosingType() |
TypeDescription |
TypeDescription.ForPackageDescription.getEnclosingType() |
static TypeDescription |
TypeDescription.ArrayProjection.of(TypeDescription componentType)
Creates an array projection of an arrity of one.
|
static TypeDescription |
TypeDescription.ArrayProjection.of(TypeDescription componentType,
int arity)
Creates an array projection.
|
TypeDescription |
TypeDescription.Generic.Visitor.Reducing.onGenericArray(TypeDescription.Generic genericArray) |
TypeDescription |
TypeDescription.Generic.Visitor.Reducing.onNonGenericType(TypeDescription.Generic typeDescription) |
TypeDescription |
TypeDescription.Generic.Visitor.Reducing.onParameterizedType(TypeDescription.Generic parameterizedType) |
TypeDescription |
TypeDescription.Generic.Visitor.Reducing.onTypeVariable(TypeDescription.Generic typeVariable) |
TypeDescription |
TypeDescription.Generic.Visitor.Reducing.onWildcard(TypeDescription.Generic wildcard) |
Modifier and Type | Method and Description |
---|---|
static TypeList.Generic |
TypeList.Generic.ForDetachedTypes.attach(TypeDescription typeDescription,
List<? extends TypeDescription.Generic> detachedTypes)
Creates a list of types that are attached to the provided type.
|
static TypeList.Generic |
TypeList.Generic.ForDetachedTypes.attachVariables(TypeDescription typeDescription,
List<? extends TypeVariableToken> detachedTypeVariables)
Creates a list of type variables that are attached to the provided type.
|
boolean |
PackageDescription.contains(TypeDescription typeDescription)
Checks if this package contains the provided type.
|
boolean |
PackageDescription.AbstractBase.contains(TypeDescription typeDescription) |
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.AbstractBase.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.AbstractBase.isAssignableTo(TypeDescription typeDescription) |
boolean |
TypeDescription.isSamePackage(TypeDescription typeDescription)
Checks if two types are defined in the same package.
|
boolean |
TypeDescription.AbstractBase.isSamePackage(TypeDescription typeDescription) |
boolean |
TypeDescription.AbstractBase.isVisibleTo(TypeDescription typeDescription) |
static TypeDescription.Generic.Visitor.Substitutor.ForAttachment |
TypeDescription.Generic.Visitor.Substitutor.ForAttachment.of(TypeDescription typeDescription)
Attaches all types to the given type description.
|
static TypeDescription.Generic |
TypeDescription.Generic.OfParameterizedType.ForGenerifiedErasure.of(TypeDescription typeDescription)
Resolves a type description to be represented as a generic type where any type with generic properties is
represented as a parameterized type and any type without such properties is represented as a non-generic
type.
|
static TypeDescription |
TypeDescription.ArrayProjection.of(TypeDescription componentType)
Creates an array projection of an arrity of one.
|
static TypeDescription |
TypeDescription.ArrayProjection.of(TypeDescription componentType,
int arity)
Creates an array projection.
|
TypeDescription.Generic |
TypeDescription.Generic.Visitor.TypeVariableErasing.TypeVariableReviser.onType(TypeDescription typeDescription) |
TypeDescription.Generic |
TypeDescription.Generic.Visitor.Substitutor.ForTypeVariableBinding.TypeVariableSubstitutor.onType(TypeDescription typeDescription) |
static TypeDescription.Generic.Builder |
TypeDescription.Generic.Builder.parameterizedType(TypeDescription rawType,
Collection<? extends TypeDefinition> parameters)
Creates a parameterized type without an owner type or with a non-generic owner type.
|
static TypeDescription.Generic.Builder |
TypeDescription.Generic.Builder.parameterizedType(TypeDescription rawType,
TypeDefinition... parameter)
Creates a parameterized type without an owner type or with a non-generic owner type.
|
static TypeDescription.Generic.Builder |
TypeDescription.Generic.Builder.parameterizedType(TypeDescription rawType,
TypeDescription.Generic ownerType,
Collection<? extends TypeDefinition> parameters)
Creates a parameterized type.
|
static TypeDescription.Generic.Builder |
TypeDescription.Generic.Builder.rawType(TypeDescription type)
Creates a raw type of a type description.
|
static TypeDescription.Generic.Builder |
TypeDescription.Generic.Builder.rawType(TypeDescription type,
TypeDescription.Generic ownerType)
Creates a raw type of a type description.
|
Modifier and Type | Method and Description |
---|---|
ByteCodeElement.Token.TokenList<TypeVariableToken> |
TypeList.Generic.asTokenList(ElementMatcher<? super TypeDescription> visitor)
Transforms a list of attached type variables into their tokenized form.
|
ByteCodeElement.Token.TokenList<TypeVariableToken> |
TypeList.Generic.AbstractBase.asTokenList(ElementMatcher<? super TypeDescription> matcher) |
ByteCodeElement.Token.TokenList<TypeVariableToken> |
TypeList.Generic.Empty.asTokenList(ElementMatcher<? super TypeDescription> matcher) |
static TypeVariableToken |
TypeVariableToken.of(TypeDescription.Generic typeVariable,
ElementMatcher<? super TypeDescription> matcher)
Transforms a type variable into a type variable token with its bounds detached.
|
protected TypeList |
TypeList.AbstractBase.wrap(List<TypeDescription> values) |
Constructor and Description |
---|
ArrayProjection(TypeDescription componentType,
int arity)
Crrates a new array projection.
|
Explicit(TypeDescription... typeDescription)
Creates an immutable wrapper.
|
ForAttachment(TypeDescription declaringType,
TypeVariableSource typeVariableSource)
Creates a visitor for attaching type variables.
|
ForGenerifiedErasure(TypeDescription typeDescription)
Creates a new parameterized type for a generified erasure.
|
ForNonGenericType(TypeDescription typeDescription)
Creates a new dispatcher of a non-generic type.
|
ForTokenNormalization(TypeDescription typeDescription)
Creates a new token normalization visitor.
|
Latent(TypeDescription typeDescription,
List<? extends AnnotationDescription> annotationDescriptions)
Creates a non-generic type with an implicit owner type.
|
Latent(TypeDescription typeDescription,
TypeDescription.Generic declaringType,
List<? extends AnnotationDescription> annotationDescriptions)
Creates a non-generic type.
|
Latent(TypeDescription rawType,
TypeDescription.Generic ownerType,
List<? extends TypeDescription.Generic> parameters,
List<? extends AnnotationDescription> declaredAnnotations)
Creates a description of a latent parameterized type.
|
OfErasure(TypeDescription typeDescription)
Creates a new raw type representation.
|
OfNonGenericType(TypeDescription typeDescription)
Creates a builder for a non-generic type.
|
OfNonGenericType(TypeDescription typeDescription,
TypeDescription.Generic ownerType)
Creates a builder for a non-generic type.
|
OfNonGenericType(TypeDescription typeDescription,
TypeDescription.Generic ownerType,
List<? extends AnnotationDescription> annotations)
Creates a builder for a non-generic type.
|
OfParameterizedType(TypeDescription rawType,
TypeDescription.Generic ownerType,
List<? extends TypeDescription.Generic> parameterTypes)
Creates a builder for a parameterized type.
|
OfParameterizedType(TypeDescription rawType,
TypeDescription.Generic ownerType,
List<? extends TypeDescription.Generic> parameterTypes,
List<? extends AnnotationDescription> annotations)
Creates a builder for a parameterized type.
|
Reducing(TypeDescription declaringType)
Creates a new reducing type visitor.
|
Reducing(TypeDescription declaringType,
List<? extends TypeVariableToken> typeVariableTokens)
Creates a new reducing type visitor.
|
Constructor and Description |
---|
Explicit(List<? extends TypeDescription> typeDescriptions)
Creates an immutable wrapper.
|
ForDetachment(ElementMatcher<? super TypeDescription> typeMatcher)
Creates a visitor for detaching a type.
|
Modifier and Type | Field and Description |
---|---|
static TypeDescription |
TargetType.DESCRIPTION
A description of the
TargetType . |
protected TypeDescription |
DynamicType.Default.typeDescription
A type description of this dynamic type.
|
Modifier and Type | Method and Description |
---|---|
TypeDescription |
DynamicType.getTypeDescription()
Returns a description of this dynamic type.
|
TypeDescription |
DynamicType.Default.getTypeDescription() |
static TypeDescription |
TargetType.resolve(TypeDescription typeDescription,
TypeDescription targetType)
Resolves the given type description to the supplied target type if it represents the
TargetType placeholder. |
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() |
Map<TypeDescription,byte[]> |
DynamicType.getAuxiliaryTypes()
Returns a map of all auxiliary types that are required for making use of the main type.
|
Map<TypeDescription,byte[]> |
DynamicType.Default.getAuxiliaryTypes() |
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() |
Map<TypeDescription,Class<?>> |
TypeResolutionStrategy.Resolved.initialize(DynamicType dynamicType,
ClassLoader classLoader,
ClassLoadingStrategy classLoadingStrategy)
Loads and initializes a dynamic type.
|
Map<TypeDescription,Class<?>> |
TypeResolutionStrategy.Passive.initialize(DynamicType dynamicType,
ClassLoader classLoader,
ClassLoadingStrategy classLoadingStrategy) |
Map<TypeDescription,Class<?>> |
TypeResolutionStrategy.Active.Resolved.initialize(DynamicType dynamicType,
ClassLoader classLoader,
ClassLoadingStrategy classLoadingStrategy) |
Map<TypeDescription,Class<?>> |
TypeResolutionStrategy.Lazy.initialize(DynamicType dynamicType,
ClassLoader classLoader,
ClassLoadingStrategy classLoadingStrategy) |
Map<TypeDescription,Class<?>> |
TypeResolutionStrategy.Disabled.initialize(DynamicType dynamicType,
ClassLoader classLoader,
ClassLoadingStrategy classLoadingStrategy) |
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 |
---|---|
static TypeDescription |
TargetType.resolve(TypeDescription typeDescription,
TypeDescription targetType)
Resolves the given type description to the supplied target type if it represents the
TargetType placeholder. |
FieldDescription.Token |
Transformer.ForField.FieldModifierTransformer.transform(TypeDescription instrumentedType,
FieldDescription.Token target) |
FieldDescription |
Transformer.ForField.transform(TypeDescription instrumentedType,
FieldDescription fieldDescription) |
MethodDescription.Token |
Transformer.ForMethod.MethodModifierTransformer.transform(TypeDescription instrumentedType,
MethodDescription.Token target) |
MethodDescription |
Transformer.ForMethod.transform(TypeDescription instrumentedType,
MethodDescription methodDescription) |
Object |
Transformer.NoOp.transform(TypeDescription instrumentedType,
Object target) |
S |
Transformer.Compound.transform(TypeDescription instrumentedType,
S target) |
T |
Transformer.transform(TypeDescription instrumentedType,
T target)
Transforms the supplied target.
|
Constructor and Description |
---|
Default(TypeDescription typeDescription,
byte[] binaryRepresentation,
LoadedTypeInitializer loadedTypeInitializer,
List<? extends DynamicType> auxiliaryTypes)
Creates a new dynamic type.
|
Loaded(TypeDescription typeDescription,
byte[] typeByte,
LoadedTypeInitializer loadedTypeInitializer,
List<? extends DynamicType> auxiliaryTypes,
Map<TypeDescription,Class<?>> loadedTypes)
Creates a new representation of a loaded dynamic type.
|
Unloaded(TypeDescription typeDescription,
byte[] binaryRepresentation,
LoadedTypeInitializer loadedTypeInitializer,
List<? extends DynamicType> auxiliaryTypes,
TypeResolutionStrategy.Resolved typeResolutionStrategy)
Creates a new unloaded representation of a dynamic type.
|
Constructor and Description |
---|
Loaded(TypeDescription typeDescription,
byte[] typeByte,
LoadedTypeInitializer loadedTypeInitializer,
List<? extends DynamicType> auxiliaryTypes,
Map<TypeDescription,Class<?>> loadedTypes)
Creates a new representation of a loaded 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.load(ClassLoader classLoader,
Map<TypeDescription,byte[]> types) |
Map<TypeDescription,Class<?>> |
ClassLoadingStrategy.Default.InjectionDispatcher.load(ClassLoader classLoader,
Map<TypeDescription,byte[]> types) |
Map<TypeDescription,Class<?>> |
ClassLoadingStrategy.Default.WrappingDispatcher.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,
AccessControlContext accessControlContext,
ByteArrayClassLoader.PersistenceHandler persistenceHandler,
PackageDefinitionStrategy packageDefinitionStrategy,
boolean childFirst,
boolean forbidExisting)
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.load(ClassLoader classLoader,
Map<TypeDescription,byte[]> types) |
Map<TypeDescription,Class<?>> |
ClassLoadingStrategy.Default.InjectionDispatcher.load(ClassLoader classLoader,
Map<TypeDescription,byte[]> types) |
Map<TypeDescription,Class<?>> |
ClassLoadingStrategy.Default.WrappingDispatcher.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,
AccessControlContext accessControlContext,
ByteArrayClassLoader.PersistenceHandler persistenceHandler,
PackageDefinitionStrategy packageDefinitionStrategy,
boolean childFirst,
boolean forbidExisting)
Loads a given set of class descriptions and their binary representations.
|
static ClassLoader |
ByteArrayClassLoader.of(ClassLoader parent,
Map<TypeDescription,byte[]> typeDefinitions,
ProtectionDomain protectionDomain,
AccessControlContext accessControlContext,
ByteArrayClassLoader.PersistenceHandler persistenceHandler,
PackageDefinitionStrategy packageDefinitionStrategy,
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.
|
static interface |
InstrumentedType.WithFlexibleName
Implementations represent an
InstrumentedType with a flexible name. |
Modifier and Type | Class and Description |
---|---|
static class |
InstrumentedType.Default
A default implementation of an instrumented type.
|
Modifier and Type | Field and Description |
---|---|
protected TypeDescription |
FieldLocator.AbstractBase.accessingType
The type accessing the field.
|
protected TypeDescription |
TypeWriter.Default.instrumentedType
The instrumented type to be created.
|
Modifier and Type | Method and Description |
---|---|
TypeDescription |
TypeWriter.MethodPool.Record.ForDefinedMethod.OfVisibilityBridge.VisibilityBridge.getDeclaringType() |
TypeDescription |
TypeWriter.MethodPool.Record.AccessBridgeWrapper.AccessorBridge.getDeclaringType() |
TypeDescription |
TypeWriter.MethodPool.Record.AccessBridgeWrapper.BridgeTarget.getDeclaringType() |
TypeDescription |
TypeWriter.Default.ForInlining.TypeInitializerDelegate.getDeclaringType() |
TypeDescription |
InstrumentedType.Default.getDeclaringType() |
TypeDescription |
InstrumentedType.Default.getEnclosingType() |
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 |
InstrumentedType.validated()
Validates the instrumented type to define a legal Java type.
|
TypeDescription |
InstrumentedType.Default.validated() |
Modifier and Type | Method and Description |
---|---|
protected MethodRegistry.Default.Prepared.Entry |
MethodRegistry.Default.Entry.asPreparedEntry(TypeDescription instrumentedType,
MethodDescription methodDescription)
Transforms this entry into a prepared state.
|
protected MethodRegistry.Default.Prepared.Entry |
MethodRegistry.Default.Entry.asPreparedEntry(TypeDescription instrumentedType,
MethodDescription methodDescription,
Set<MethodDescription.TypeToken> methodTypes)
Transforms this entry into a prepared state.
|
protected TypeWriter.MethodPool.Record |
MethodRegistry.Default.Compiled.Entry.bind(TypeDescription instrumentedType,
boolean supportsBridges)
Transforms this entry into a method record.
|
protected TypeWriter.FieldPool.Record |
FieldRegistry.Default.Compiled.Entry.bind(TypeDescription instrumentedType,
FieldDescription fieldDescription)
Binds this entry to the provided field description.
|
MethodGraph.Linked |
MethodGraph.Empty.compile(TypeDefinition typeDefinition,
TypeDescription viewPoint) |
MethodGraph.Linked |
MethodGraph.Compiler.compile(TypeDefinition typeDefinition,
TypeDescription viewPoint)
Compiles the given type into a method graph.
|
MethodGraph.Linked |
MethodGraph.Compiler.Default.compile(TypeDefinition typeDefinition,
TypeDescription viewPoint) |
MethodGraph.Linked |
MethodGraph.Empty.compile(TypeDescription typeDescription) |
MethodGraph.Linked |
MethodGraph.Compiler.compile(TypeDescription typeDescription)
Compiles the given type into a method graph considering the type to be the viewpoint.
|
MethodGraph.Linked |
MethodGraph.Compiler.AbstractBase.compile(TypeDescription typeDescription) |
FieldRegistry.Compiled |
FieldRegistry.compile(TypeDescription instrumentedType)
Prepares the field registry for a given instrumented type.
|
FieldRegistry.Compiled |
FieldRegistry.Default.compile(TypeDescription instrumentedType) |
static <U> TypeWriter<U> |
TypeWriter.Default.forRebasing(MethodRegistry.Prepared methodRegistry,
TypeWriter.FieldPool fieldPool,
TypeAttributeAppender typeAttributeAppender,
AsmVisitorWrapper asmVisitorWrapper,
ClassFileVersion classFileVersion,
AnnotationValueFilter.Factory annotationValueFilterFactory,
AnnotationRetention annotationRetention,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
Implementation.Context.Factory implementationContextFactory,
TypeValidation typeValidation,
TypePool typePool,
TypeDescription originalType,
ClassFileLocator classFileLocator,
MethodRebaseResolver methodRebaseResolver)
Creates a type writer for rebasing a type.
|
static <U> TypeWriter<U> |
TypeWriter.Default.forRedefinition(MethodRegistry.Prepared methodRegistry,
TypeWriter.FieldPool fieldPool,
TypeAttributeAppender typeAttributeAppender,
AsmVisitorWrapper asmVisitorWrapper,
ClassFileVersion classFileVersion,
AnnotationValueFilter.Factory annotationValueFilterFactory,
AnnotationRetention annotationRetention,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
Implementation.Context.Factory implementationContextFactory,
TypeValidation typeValidation,
TypePool typePool,
TypeDescription originalType,
ClassFileLocator classFileLocator)
Creates a type writer for redefining a type.
|
MethodGraph |
MethodGraph.Empty.getInterfaceGraph(TypeDescription typeDescription) |
MethodGraph |
MethodGraph.Linked.getInterfaceGraph(TypeDescription typeDescription)
Returns a graph representing the view on this represented type's directly implemented interface type.
|
MethodGraph |
MethodGraph.Linked.Delegation.getInterfaceGraph(TypeDescription typeDescription) |
FieldLocator.Resolution |
FieldLocator.locate(String name,
TypeDescription type)
Locates a field with the given name and type and throws an exception if no such type exists.
|
FieldLocator.Resolution |
FieldLocator.NoOp.locate(String name,
TypeDescription type) |
FieldLocator.Resolution |
FieldLocator.AbstractBase.locate(String name,
TypeDescription type) |
FieldLocator |
FieldLocator.Factory.make(TypeDescription typeDescription)
Creates a field locator for a given type.
|
FieldLocator |
FieldLocator.NoOp.make(TypeDescription typeDescription) |
FieldLocator |
FieldLocator.ForExactType.Factory.make(TypeDescription typeDescription) |
FieldLocator |
FieldLocator.ForClassHierarchy.Factory.make(TypeDescription typeDescription) |
static InstrumentedType.WithFlexibleName |
InstrumentedType.Default.of(TypeDescription typeDescription)
Creates an instrumented type that represents the given type description.
|
static TypeWriter.MethodPool.Record |
TypeWriter.MethodPool.Record.ForDefinedMethod.OfVisibilityBridge.of(TypeDescription instrumentedType,
MethodDescription bridgeTarget,
MethodAttributeAppender attributeAppender)
Creates a record for a visibility bridge.
|
static TypeWriter.MethodPool.Record |
TypeWriter.MethodPool.Record.AccessBridgeWrapper.of(TypeWriter.MethodPool.Record delegate,
TypeDescription instrumentedType,
MethodDescription bridgeTarget,
Set<MethodDescription.TypeToken> bridgeTypes,
MethodAttributeAppender attributeAppender)
Wraps the given record in an accessor bridge wrapper if necessary.
|
ElementMatcher<? super MethodDescription> |
MethodRegistry.Default.Entry.resolve(TypeDescription typeDescription) |
ElementMatcher<? super FieldDescription> |
FieldRegistry.Default.Entry.resolve(TypeDescription typeDescription) |
Constructor and Description |
---|
AbstractBase(TypeDescription accessingType)
Creates a new field locator.
|
AccessBridgeWrapper(TypeWriter.MethodPool.Record delegate,
TypeDescription instrumentedType,
MethodDescription bridgeTarget,
Set<MethodDescription.TypeToken> bridgeTypes,
MethodAttributeAppender attributeAppender)
Creates a wrapper for adding accessor bridges.
|
AccessorBridge(MethodDescription bridgeTarget,
MethodDescription.TypeToken bridgeType,
TypeDescription instrumentedType)
Creates a new accessor bridge method.
|
BridgeTarget(MethodDescription bridgeTarget,
TypeDescription instrumentedType)
Creates a new bridge target.
|
Compiled(TypeDescription instrumentedType)
Creates a new compiled handler for a visibility bridge.
|
Compiled(TypeDescription instrumentedType,
List<FieldRegistry.Default.Compiled.Entry> entries)
Creates a new compiled field registry.
|
Compiled(TypeDescription instrumentedType,
LoadedTypeInitializer loadedTypeInitializer,
TypeInitializer typeInitializer,
LinkedHashMap<MethodDescription,MethodRegistry.Default.Compiled.Entry> implementations,
boolean supportsBridges)
Creates a new compiled version of a default method registry.
|
Default(String name,
int modifiers,
TypeDescription.Generic superClass,
List<? extends TypeVariableToken> typeVariables,
List<? extends TypeDescription.Generic> interfaceTypes,
List<? extends FieldDescription.Token> fieldTokens,
List<? extends MethodDescription.Token> methodTokens,
List<? extends AnnotationDescription> annotationDescriptions,
TypeInitializer typeInitializer,
LoadedTypeInitializer loadedTypeInitializer,
TypeDescription declaringType,
MethodDescription enclosingMethod,
TypeDescription enclosingType,
List<? extends TypeDescription> declaredTypes,
boolean memberClass,
boolean anonymousClass,
boolean localClass)
Creates a new instrumented type.
|
Default(TypeDescription instrumentedType,
ClassFileVersion classFileVersion,
TypeWriter.FieldPool fieldPool,
List<? extends DynamicType> auxiliaryTypes,
MethodList<?> instrumentedMethods,
LoadedTypeInitializer loadedTypeInitializer,
TypeInitializer typeInitializer,
TypeAttributeAppender typeAttributeAppender,
AsmVisitorWrapper asmVisitorWrapper,
AnnotationValueFilter.Factory annotationValueFilterFactory,
AnnotationRetention annotationRetention,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
Implementation.Context.Factory implementationContextFactory,
TypeValidation typeValidation,
TypePool typePool)
Creates a new default type writer.
|
Factory(TypeDescription typeDescription)
Creates a new factory for a field locator that locates a field for an exact type.
|
ForClassHierarchy(TypeDescription typeDescription)
Creates a field locator that looks up fields that are declared within a class's class hierarchy.
|
ForClassHierarchy(TypeDescription typeDescription,
TypeDescription accessingType)
Creates a field locator that looks up fields that are declared within a class's class hierarchy.
|
ForCreation(TypeDescription instrumentedType,
ClassFileVersion classFileVersion,
TypeWriter.FieldPool fieldPool,
TypeWriter.MethodPool methodPool,
List<? extends DynamicType> auxiliaryTypes,
MethodList<?> instrumentedMethods,
LoadedTypeInitializer loadedTypeInitializer,
TypeInitializer typeInitializer,
TypeAttributeAppender typeAttributeAppender,
AsmVisitorWrapper asmVisitorWrapper,
AnnotationValueFilter.Factory annotationValueFilterFactory,
AnnotationRetention annotationRetention,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
Implementation.Context.Factory implementationContextFactory,
TypeValidation typeValidation,
TypePool typePool)
Creates a new default type writer for creating a new type that is not based on an existing class file.
|
ForExactType(TypeDescription typeDescription)
Creates a new field locator for locating fields from a declared type.
|
ForExactType(TypeDescription typeDescription,
TypeDescription accessingType)
Creates a new field locator for locating fields from a declared type.
|
ForInlining(TypeDescription instrumentedType,
ClassFileVersion classFileVersion,
TypeWriter.FieldPool fieldPool,
MethodRegistry.Prepared methodRegistry,
Implementation.Target.Factory implementationTargetFactory,
List<DynamicType> explicitAuxiliaryTypes,
MethodList<?> instrumentedMethods,
LoadedTypeInitializer loadedTypeInitializer,
TypeInitializer typeInitializer,
TypeAttributeAppender typeAttributeAppender,
AsmVisitorWrapper asmVisitorWrapper,
AnnotationValueFilter.Factory annotationValueFilterFactory,
AnnotationRetention annotationRetention,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
Implementation.Context.Factory implementationContextFactory,
TypeValidation typeValidation,
TypePool typePool,
TypeDescription originalType,
ClassFileLocator classFileLocator,
MethodRebaseResolver methodRebaseResolver)
Creates a new default type writer for creating a new type that is not based on an existing class file.
|
OfVisibilityBridge(MethodDescription visibilityBridge,
MethodDescription bridgeTarget,
TypeDescription superClass,
MethodAttributeAppender attributeAppender)
Creates a new record for a visibility bridge.
|
Prepared(LinkedHashMap<MethodDescription,MethodRegistry.Default.Prepared.Entry> implementations,
LoadedTypeInitializer loadedTypeInitializer,
TypeInitializer typeInitializer,
TypeDescription instrumentedType,
MethodGraph.Linked methodGraph)
Creates a prepared version of a default method registry.
|
TypeInitializerDelegate(TypeDescription instrumentedType,
String suffix)
Creates a new type initializer delegate.
|
VisibilityBridge(TypeDescription instrumentedType,
MethodDescription bridgeTarget)
Creates a new visibility bridge.
|
Constructor and Description |
---|
Default(String name,
int modifiers,
TypeDescription.Generic superClass,
List<? extends TypeVariableToken> typeVariables,
List<? extends TypeDescription.Generic> interfaceTypes,
List<? extends FieldDescription.Token> fieldTokens,
List<? extends MethodDescription.Token> methodTokens,
List<? extends AnnotationDescription> annotationDescriptions,
TypeInitializer typeInitializer,
LoadedTypeInitializer loadedTypeInitializer,
TypeDescription declaringType,
MethodDescription enclosingMethod,
TypeDescription enclosingType,
List<? extends TypeDescription> declaredTypes,
boolean memberClass,
boolean anonymousClass,
boolean localClass)
Creates a new instrumented type.
|
Delegation(MethodGraph methodGraph,
MethodGraph superClassGraph,
Map<TypeDescription,MethodGraph> interfaceGraphs)
Creates a new delegation method graph.
|
Modifier and Type | Field and Description |
---|---|
protected TypeDescription |
AbstractInliningDynamicTypeBuilder.originalType
The original type that is being redefined or rebased.
|
Modifier and Type | Method and Description |
---|---|
TypeDescription |
MethodRebaseResolver.Resolution.ForRebasedMethod.RebasedMethod.getDeclaringType() |
TypeDescription |
MethodRebaseResolver.Resolution.ForRebasedConstructor.RebasedConstructor.getDeclaringType() |
TypeDescription |
RebaseImplementationTarget.getOriginType() |
TypeDescription |
RebaseImplementationTarget.RebasedMethodInvocation.getTypeDescription() |
Modifier and Type | Method and Description |
---|---|
Implementation.Target |
RebaseImplementationTarget.Factory.make(TypeDescription instrumentedType,
MethodGraph.Linked methodGraph,
ClassFileVersion classFileVersion) |
static MethodRebaseResolver |
MethodRebaseResolver.Default.make(TypeDescription instrumentedType,
Set<? extends MethodDescription.Token> rebaseableMethodTokens,
ClassFileVersion classFileVersion,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
MethodNameTransformer methodNameTransformer)
Creates a new method rebase resolver.
|
protected static LatentMatcher<MethodDescription> |
InliningImplementationMatcher.of(LatentMatcher<? super MethodDescription> ignoredMethods,
TypeDescription originalType)
Creates a matcher where only overridable or declared methods are matched unless those are ignored.
|
static MethodRebaseResolver.Resolution |
MethodRebaseResolver.Resolution.ForRebasedConstructor.of(MethodDescription.InDefinedShape methodDescription,
TypeDescription placeholderType)
Resolves a constructor rebasement.
|
protected static Implementation.SpecialMethodInvocation |
RebaseImplementationTarget.RebasedMethodInvocation.of(MethodDescription resolvedMethod,
TypeDescription instrumentedType,
StackManipulation additionalArguments)
Creates a special method invocation for the given method.
|
protected static Implementation.Target |
RebaseImplementationTarget.of(TypeDescription instrumentedType,
MethodGraph.Linked methodGraph,
ClassFileVersion classFileVersion,
MethodRebaseResolver methodRebaseResolver)
Creates a new rebase implementation target.
|
protected static ElementMatcher<MethodDescription> |
RebaseDynamicTypeBuilder.RebaseableMatcher.of(TypeDescription instrumentedType,
MethodList<?> instrumentedMethods)
Returns a matcher that filters any method that should not be rebased.
|
ElementMatcher<? super MethodDescription> |
InliningImplementationMatcher.resolve(TypeDescription typeDescription) |
Constructor and Description |
---|
AbstractInliningDynamicTypeBuilder(InstrumentedType.WithFlexibleName instrumentedType,
FieldRegistry fieldRegistry,
MethodRegistry methodRegistry,
TypeAttributeAppender typeAttributeAppender,
AsmVisitorWrapper asmVisitorWrapper,
ClassFileVersion classFileVersion,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
AnnotationValueFilter.Factory annotationValueFilterFactory,
AnnotationRetention annotationRetention,
Implementation.Context.Factory implementationContextFactory,
MethodGraph.Compiler methodGraphCompiler,
TypeValidation typeValidation,
LatentMatcher<? super MethodDescription> ignoredMethods,
TypeDescription originalType,
ClassFileLocator classFileLocator)
Creates an inlining dynamic type builder.
|
RebaseableMatcher(TypeDescription instrumentedType,
Set<MethodDescription.Token> instrumentedMethods)
Creates a new matcher for identifying rebasable methods.
|
RebasedConstructor(MethodDescription.InDefinedShape methodDescription,
TypeDescription placeholderType)
Creates a new rebased constructor.
|
RebasedMethodInvocation(MethodDescription methodDescription,
TypeDescription instrumentedType,
StackManipulation stackManipulation)
Creates a new rebased method invocation.
|
RebaseDynamicTypeBuilder(InstrumentedType.WithFlexibleName instrumentedType,
ClassFileVersion classFileVersion,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
AnnotationValueFilter.Factory annotationValueFilterFactory,
AnnotationRetention annotationRetention,
Implementation.Context.Factory implementationContextFactory,
MethodGraph.Compiler methodGraphCompiler,
TypeValidation typeValidation,
LatentMatcher<? super MethodDescription> ignoredMethods,
TypeDescription originalType,
ClassFileLocator classFileLocator,
MethodNameTransformer methodNameTransformer)
Creates a rebase dynamic type builder.
|
RebaseDynamicTypeBuilder(InstrumentedType.WithFlexibleName instrumentedType,
FieldRegistry fieldRegistry,
MethodRegistry methodRegistry,
TypeAttributeAppender typeAttributeAppender,
AsmVisitorWrapper asmVisitorWrapper,
ClassFileVersion classFileVersion,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
AnnotationValueFilter.Factory annotationValueFilterFactory,
AnnotationRetention annotationRetention,
Implementation.Context.Factory implementationContextFactory,
MethodGraph.Compiler methodGraphCompiler,
TypeValidation typeValidation,
LatentMatcher<? super MethodDescription> ignoredMethods,
TypeDescription originalType,
ClassFileLocator classFileLocator,
MethodNameTransformer methodNameTransformer)
Creates a rebase dynamic type builder.
|
RebaseImplementationTarget(TypeDescription instrumentedType,
MethodGraph.Linked methodGraph,
Implementation.Target.AbstractBase.DefaultMethodInvocation defaultMethodInvocation,
Map<MethodDescription.SignatureToken,MethodRebaseResolver.Resolution> rebaseableMethods)
Creates a rebase implementation target.
|
RedefinitionDynamicTypeBuilder(InstrumentedType.WithFlexibleName instrumentedType,
ClassFileVersion classFileVersion,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
AnnotationValueFilter.Factory annotationValueFilterFactory,
AnnotationRetention annotationRetention,
Implementation.Context.Factory implementationContextFactory,
MethodGraph.Compiler methodGraphCompiler,
TypeValidation typeValidation,
LatentMatcher<? super MethodDescription> ignoredMethods,
TypeDescription originalType,
ClassFileLocator classFileLocator)
Creates a redefinition dynamic type builder.
|
RedefinitionDynamicTypeBuilder(InstrumentedType.WithFlexibleName instrumentedType,
FieldRegistry fieldRegistry,
MethodRegistry methodRegistry,
TypeAttributeAppender typeAttributeAppender,
AsmVisitorWrapper asmVisitorWrapper,
ClassFileVersion classFileVersion,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
AnnotationValueFilter.Factory annotationValueFilterFactory,
AnnotationRetention annotationRetention,
Implementation.Context.Factory implementationContextFactory,
MethodGraph.Compiler methodGraphCompiler,
TypeValidation typeValidation,
LatentMatcher<? super MethodDescription> ignoredMethods,
TypeDescription originalType,
ClassFileLocator classFileLocator)
Creates a redefinition dynamic type builder.
|
Modifier and Type | Method and Description |
---|---|
protected abstract List<MethodDescription.Token> |
ConstructorStrategy.Default.doExtractConstructors(TypeDescription instrumentedType)
Extracts the relevant method tokens of the instrumented type's constructors.
|
List<MethodDescription.Token> |
ConstructorStrategy.extractConstructors(TypeDescription instrumentedType)
Extracts constructors for a given super type.
|
List<MethodDescription.Token> |
ConstructorStrategy.Default.extractConstructors(TypeDescription instrumentedType) |
protected abstract TypeDefinition |
SubclassImplementationTarget.OriginTypeResolver.identify(TypeDescription typeDescription)
Identifies the origin type to a given type description.
|
Implementation.Target |
SubclassImplementationTarget.Factory.make(TypeDescription instrumentedType,
MethodGraph.Linked methodGraph,
ClassFileVersion classFileVersion) |
ElementMatcher<? super MethodDescription> |
SubclassDynamicTypeBuilder.InstrumentableMatcher.resolve(TypeDescription typeDescription) |
Constructor and Description |
---|
SubclassImplementationTarget(TypeDescription instrumentedType,
MethodGraph.Linked methodGraph,
Implementation.Target.AbstractBase.DefaultMethodInvocation defaultMethodInvocation,
SubclassImplementationTarget.OriginTypeResolver originTypeResolver)
Creates a new subclass implementation target.
|
Modifier and Type | Field and Description |
---|---|
protected TypeDescription |
Implementation.Target.AbstractBase.instrumentedType
The instrumented type.
|
protected TypeDescription |
Implementation.Context.ExtractableView.AbstractBase.instrumentedType
The instrumented type.
|
Modifier and Type | Method and Description |
---|---|
TypeDescription |
Implementation.Context.Default.CacheValueField.getDeclaringType() |
TypeDescription |
Implementation.Context.Default.AccessorMethod.getDeclaringType() |
TypeDescription |
Implementation.Context.Default.FieldGetter.getDeclaringType() |
TypeDescription |
Implementation.Context.Default.FieldSetter.getDeclaringType() |
TypeDescription |
Implementation.Context.Default.FieldCacheEntry.getFieldType()
Returns the field type that is represented by this field cache entry.
|
TypeDescription |
Implementation.Target.getInstrumentedType()
Returns a description of the instrumented type.
|
TypeDescription |
Implementation.Target.AbstractBase.getInstrumentedType() |
TypeDescription |
Implementation.Context.getInstrumentedType()
Returns the instrumented type of the current implementation.
|
TypeDescription |
Implementation.Context.ExtractableView.AbstractBase.getInstrumentedType() |
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.Context.register(AuxiliaryType auxiliaryType)
Registers an auxiliary type as required for the current implementation.
|
TypeDescription |
Implementation.Context.Disabled.register(AuxiliaryType auxiliaryType) |
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 abstract Implementation.SpecialMethodInvocation |
Implementation.Target.AbstractBase.DefaultMethodInvocation.apply(MethodGraph.Node node,
TypeDescription targetType)
Resolves a default method invocation for a given node.
|
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.
|
InvokeDynamic |
InvokeDynamic.WithImplicitArgumentType.as(TypeDescription typeDescription)
Defines the given argument to be treated as an instance of the provided type.
|
FieldDescription.InDefinedShape |
Implementation.Context.cache(StackManipulation fieldValue,
TypeDescription fieldType)
Caches a single value by storing it in form of a
private , final and static field. |
FieldDescription.InDefinedShape |
Implementation.Context.Disabled.cache(StackManipulation fieldValue,
TypeDescription fieldType) |
FieldDescription.InDefinedShape |
Implementation.Context.Default.cache(StackManipulation fieldValue,
TypeDescription fieldType) |
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,
MethodDescription.SignatureToken token)
Creates a special method invocation for invoking a default method.
|
Implementation.SpecialMethodInvocation |
Implementation.Target.AbstractBase.invokeDefault(TypeDescription targetType,
MethodDescription.SignatureToken token) |
Implementation.Context.ExtractableView |
Implementation.Context.Factory.make(TypeDescription instrumentedType,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
TypeInitializer typeInitializer,
ClassFileVersion classFileVersion,
ClassFileVersion auxiliaryClassFileVersion)
Creates a new implementation context.
|
Implementation.Context.ExtractableView |
Implementation.Context.Disabled.Factory.make(TypeDescription instrumentedType,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
TypeInitializer typeInitializer,
ClassFileVersion classFileVersion,
ClassFileVersion auxiliaryClassFileVersion) |
Implementation.Context.ExtractableView |
Implementation.Context.Default.Factory.make(TypeDescription instrumentedType,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
TypeInitializer typeInitializer,
ClassFileVersion classFileVersion,
ClassFileVersion auxiliaryClassFileVersion) |
List<MethodCall.ArgumentLoader> |
MethodCall.ArgumentLoader.Factory.make(TypeDescription instrumentedType,
MethodDescription instrumentedMethod)
Creates any number of argument loaders for an instrumentation.
|
List<MethodCall.ArgumentLoader> |
MethodCall.ArgumentLoader.ForNullConstant.make(TypeDescription instrumentedType,
MethodDescription instrumentedMethod) |
List<MethodCall.ArgumentLoader> |
MethodCall.ArgumentLoader.ForThisReference.Factory.make(TypeDescription instrumentedType,
MethodDescription instrumentedMethod) |
List<MethodCall.ArgumentLoader> |
MethodCall.ArgumentLoader.ForInstrumentedType.Factory.make(TypeDescription instrumentedType,
MethodDescription instrumentedMethod) |
List<MethodCall.ArgumentLoader> |
MethodCall.ArgumentLoader.ForMethodParameter.OfInstrumentedMethod.make(TypeDescription instrumentedType,
MethodDescription instrumentedMethod) |
List<MethodCall.ArgumentLoader> |
MethodCall.ArgumentLoader.ForMethodParameter.Factory.make(TypeDescription instrumentedType,
MethodDescription instrumentedMethod) |
List<MethodCall.ArgumentLoader> |
MethodCall.ArgumentLoader.ForStaticField.Factory.make(TypeDescription instrumentedType,
MethodDescription instrumentedMethod) |
List<MethodCall.ArgumentLoader> |
MethodCall.ArgumentLoader.ForInstanceField.Factory.make(TypeDescription instrumentedType,
MethodDescription instrumentedMethod) |
List<MethodCall.ArgumentLoader> |
MethodCall.ArgumentLoader.ForExistingField.Factory.make(TypeDescription instrumentedType,
MethodDescription instrumentedMethod) |
List<MethodCall.ArgumentLoader> |
MethodCall.ArgumentLoader.ForBooleanConstant.make(TypeDescription instrumentedType,
MethodDescription instrumentedMethod) |
List<MethodCall.ArgumentLoader> |
MethodCall.ArgumentLoader.ForByteConstant.make(TypeDescription instrumentedType,
MethodDescription instrumentedMethod) |
List<MethodCall.ArgumentLoader> |
MethodCall.ArgumentLoader.ForShortConstant.make(TypeDescription instrumentedType,
MethodDescription instrumentedMethod) |
List<MethodCall.ArgumentLoader> |
MethodCall.ArgumentLoader.ForCharacterConstant.make(TypeDescription instrumentedType,
MethodDescription instrumentedMethod) |
List<MethodCall.ArgumentLoader> |
MethodCall.ArgumentLoader.ForIntegerConstant.make(TypeDescription instrumentedType,
MethodDescription instrumentedMethod) |
List<MethodCall.ArgumentLoader> |
MethodCall.ArgumentLoader.ForLongConstant.make(TypeDescription instrumentedType,
MethodDescription instrumentedMethod) |
List<MethodCall.ArgumentLoader> |
MethodCall.ArgumentLoader.ForFloatConstant.make(TypeDescription instrumentedType,
MethodDescription instrumentedMethod) |
List<MethodCall.ArgumentLoader> |
MethodCall.ArgumentLoader.ForDoubleConstant.make(TypeDescription instrumentedType,
MethodDescription instrumentedMethod) |
List<MethodCall.ArgumentLoader> |
MethodCall.ArgumentLoader.ForTextConstant.make(TypeDescription instrumentedType,
MethodDescription instrumentedMethod) |
List<MethodCall.ArgumentLoader> |
MethodCall.ArgumentLoader.ForClassConstant.make(TypeDescription instrumentedType,
MethodDescription instrumentedMethod) |
List<MethodCall.ArgumentLoader> |
MethodCall.ArgumentLoader.ForEnumerationValue.make(TypeDescription instrumentedType,
MethodDescription instrumentedMethod) |
List<MethodCall.ArgumentLoader> |
MethodCall.ArgumentLoader.ForJavaConstant.make(TypeDescription instrumentedType,
MethodDescription instrumentedMethod) |
Implementation.Target |
Implementation.Target.Factory.make(TypeDescription instrumentedType,
MethodGraph.Linked methodGraph,
ClassFileVersion classFileVersion)
Creates an implementation target.
|
static Implementation.SpecialMethodInvocation |
Implementation.SpecialMethodInvocation.Simple.of(MethodDescription methodDescription,
TypeDescription typeDescription)
Creates a special method invocation for a given invocation target.
|
protected static MethodDelegation.MethodContainer |
MethodDelegation.MethodContainer.ForExplicitMethods.ofConstructors(TypeDescription typeDescription)
Creates a container for all constructors of the given type description.
|
protected static MethodDelegation.MethodContainer |
MethodDelegation.MethodContainer.ForExplicitMethods.ofStatic(TypeDescription typeDescription)
Creates a container for all static methods of the given type description.
|
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 invokedMethod,
MethodDescription instrumentedMethod,
TypeDescription instrumentedType,
Assigner assigner,
Assigner.Typing typing)
Creates a stack manipulation that represents the method's invocation.
|
StackManipulation |
MethodCall.TargetHandler.ForSelfOrStaticInvocation.resolve(MethodDescription invokedMethod,
MethodDescription instrumentedMethod,
TypeDescription instrumentedType,
Assigner assigner,
Assigner.Typing typing) |
StackManipulation |
MethodCall.TargetHandler.ForConstructingInvocation.resolve(MethodDescription invokedMethod,
MethodDescription instrumentedMethod,
TypeDescription instrumentedType,
Assigner assigner,
Assigner.Typing typing) |
StackManipulation |
MethodCall.TargetHandler.ForStaticField.resolve(MethodDescription invokedMethod,
MethodDescription instrumentedMethod,
TypeDescription instrumentedType,
Assigner assigner,
Assigner.Typing typing) |
StackManipulation |
MethodCall.TargetHandler.ForInstanceField.resolve(MethodDescription invokedMethod,
MethodDescription instrumentedMethod,
TypeDescription instrumentedType,
Assigner assigner,
Assigner.Typing typing) |
StackManipulation |
MethodCall.TargetHandler.ForMethodParameter.resolve(MethodDescription invokedMethod,
MethodDescription instrumentedMethod,
TypeDescription instrumentedType,
Assigner assigner,
Assigner.Typing typing) |
StackManipulation |
InvokeDynamic.TerminationHandler.resolve(MethodDescription interceptedMethod,
TypeDescription returnType,
Assigner assigner,
Assigner.Typing typing)
Returns a stack manipulation that handles the method return.
|
StackManipulation |
InvokeDynamic.TerminationHandler.ForMethodReturn.resolve(MethodDescription interceptedMethod,
TypeDescription returnType,
Assigner assigner,
Assigner.Typing typing) |
StackManipulation |
InvokeDynamic.TerminationHandler.ForChainedInvocation.resolve(MethodDescription interceptedMethod,
TypeDescription returnType,
Assigner assigner,
Assigner.Typing typing) |
MethodList<?> |
MethodDelegation.MethodContainer.resolve(TypeDescription instrumentedType)
Resolves this method container to extract a list of methods to be considered for interception.
|
MethodList<?> |
MethodDelegation.MethodContainer.ForExplicitMethods.resolve(TypeDescription instrumentedType) |
MethodList<?> |
MethodDelegation.MethodContainer.ForVirtualMethods.resolve(TypeDescription instrumentedType) |
InvokeDynamic.InvocationProvider.Target.Resolved |
InvokeDynamic.InvocationProvider.Target.resolve(TypeDescription instrumentedType,
Assigner assigner,
Assigner.Typing typing)
Resolves the target.
|
InvokeDynamic.InvocationProvider.Target.Resolved |
InvokeDynamic.InvocationProvider.Target.ForMethodDescription.resolve(TypeDescription instrumentedType,
Assigner assigner,
Assigner.Typing typing) |
InvokeDynamic.InvocationProvider.Target.Resolved |
InvokeDynamic.InvocationProvider.Default.Target.resolve(TypeDescription instrumentedType,
Assigner assigner,
Assigner.Typing typing) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
Assigner.Typing typing)
Resolves an argument provider.
|
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForInterceptedMethodInstanceAndParameters.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
Assigner.Typing typing) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForInterceptedMethodParameters.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
Assigner.Typing typing) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ConstantPoolWrapper.WrappingArgumentProvider.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
Assigner.Typing typing) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForThisInstance.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
Assigner.Typing typing) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForStaticField.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
Assigner.Typing typing) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForInstanceField.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
Assigner.Typing typing) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForExistingField.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
Assigner.Typing typing) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForMethodParameter.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
Assigner.Typing typing) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForExplicitTypedMethodParameter.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
Assigner.Typing typing) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForBooleanConstant.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
Assigner.Typing typing) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForByteConstant.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
Assigner.Typing typing) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForShortConstant.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
Assigner.Typing typing) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForCharacterConstant.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
Assigner.Typing typing) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForIntegerConstant.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
Assigner.Typing typing) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForLongConstant.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
Assigner.Typing typing) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForFloatConstant.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
Assigner.Typing typing) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForDoubleConstant.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
Assigner.Typing typing) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForStringConstant.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
Assigner.Typing typing) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForClassConstant.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
Assigner.Typing typing) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForEnumerationValue.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
Assigner.Typing typing) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForNullValue.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
Assigner.Typing typing) |
InvokeDynamic.InvocationProvider.ArgumentProvider.Resolved |
InvokeDynamic.InvocationProvider.ArgumentProvider.ForJavaConstant.resolve(TypeDescription instrumentedType,
MethodDescription instrumentedMethod,
Assigner assigner,
Assigner.Typing typing) |
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 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 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.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 |
---|
AbstractBase(TypeDescription instrumentedType,
ClassFileVersion classFileVersion)
Create a new extractable view.
|
AbstractBase(TypeDescription instrumentedType,
MethodGraph.Linked methodGraph,
Implementation.Target.AbstractBase.DefaultMethodInvocation defaultMethodInvocation)
Creates a new implementation target.
|
AccessorMethod(TypeDescription instrumentedType,
MethodDescription methodDescription,
String suffix)
Creates a new accessor method.
|
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.
|
Appender(TypeDescription originType)
Creates a new appender.
|
CacheValueField(TypeDescription instrumentedType,
TypeDescription.Generic fieldType,
String suffix,
int valueHashCode)
Creates a new cache value field.
|
Default(TypeDescription instrumentedType,
ClassFileVersion classFileVersion,
AuxiliaryType.NamingStrategy auxiliaryTypeNamingStrategy,
TypeInitializer typeInitializer,
ClassFileVersion auxiliaryClassFileVersion)
Creates a new default implementation context.
|
Disabled(TypeDescription instrumentedType,
ClassFileVersion classFileVersion)
Creates a new disabled implementation context.
|
ExceptionMethod(TypeDescription throwableType,
ExceptionMethod.ConstructionDelegate constructionDelegate)
Creates a new instance of an implementation for throwing throwables.
|
FieldCacheEntry(StackManipulation fieldValue,
TypeDescription fieldType)
Creates a new field cache entry.
|
FieldGetter(TypeDescription instrumentedType,
FieldDescription fieldDescription,
String suffix)
Creates a new field getter.
|
FieldSetter(TypeDescription instrumentedType,
FieldDescription fieldDescription,
String suffix)
Creates a new field setter.
|
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.
|
ForInstrumentedType(TypeDescription instrumentedType)
Creates an argument loader for supporting the instrumented type as a type constant as an argument.
|
ForNullValue(TypeDescription typeDescription)
Creates a new argument provider for the
null value. |
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.
|
ForThisReference(TypeDescription instrumentedType)
Creates an argument loader that supplies the
this instance as an argument. |
ForVirtualInvocation(TypeDescription typeDescription)
Creates a new method invoking for a virtual method invocation.
|
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 instrumentedType,
AnnotationValueFilter annotationValueFilter)
Applies this type attribute appender.
|
void |
TypeAttributeAppender.NoOp.apply(ClassVisitor classVisitor,
TypeDescription instrumentedType,
AnnotationValueFilter annotationValueFilter) |
void |
TypeAttributeAppender.ForInstrumentedType.apply(ClassVisitor classVisitor,
TypeDescription instrumentedType,
AnnotationValueFilter annotationValueFilter) |
void |
TypeAttributeAppender.ForInstrumentedType.Differentiating.apply(ClassVisitor classVisitor,
TypeDescription instrumentedType,
AnnotationValueFilter annotationValueFilter) |
void |
TypeAttributeAppender.Explicit.apply(ClassVisitor classVisitor,
TypeDescription instrumentedType,
AnnotationValueFilter annotationValueFilter) |
void |
TypeAttributeAppender.Compound.apply(ClassVisitor classVisitor,
TypeDescription instrumentedType,
AnnotationValueFilter annotationValueFilter) |
MethodAttributeAppender |
MethodAttributeAppender.NoOp.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.ForInstrumentedMethod.make(TypeDescription typeDescription) |
MethodAttributeAppender |
MethodAttributeAppender.Explicit.make(TypeDescription typeDescription) |
MethodAttributeAppender |
MethodAttributeAppender.ForReceiverType.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.ForInstrumentedField.make(TypeDescription typeDescription) |
FieldAttributeAppender |
FieldAttributeAppender.Explicit.make(TypeDescription typeDescription) |
AnnotationValueFilter |
AnnotationValueFilter.Factory.on(TypeDescription instrumentedType)
Creates an annotation value filter for writing annotations on an instrumented type.
|
AnnotationValueFilter |
AnnotationValueFilter.Default.on(TypeDescription instrumentedType) |
Constructor and Description |
---|
Differentiating(TypeDescription typeDescription)
Creates a new differentiating type attribute appender.
|
Modifier and Type | Method and Description |
---|---|
MethodGraph.Linked |
MethodCallProxy.PrecomputedMethodGraph.compile(TypeDefinition typeDefinition,
TypeDescription viewPoint) |
MethodGraph.Linked |
MethodCallProxy.PrecomputedMethodGraph.compile(TypeDescription typeDescription) |
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(TypeDescription instrumentedType)
Names an auxiliary type.
|
String |
AuxiliaryType.NamingStrategy.SuffixingRandom.name(TypeDescription instrumentedType) |
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 |
---|---|
protected TypeDescription |
FieldProxy.Binder.declaringType(AnnotationDescription.Loadable<FieldProxy> annotation) |
protected TypeDescription |
FieldValue.Binder.Delegate.declaringType(AnnotationDescription.Loadable<FieldValue> annotation) |
protected abstract TypeDescription |
TargetMethodAnnotationDrivenBinder.ParameterBinder.ForFieldBinding.declaringType(AnnotationDescription.Loadable<S> annotation)
Extracts the declaring type from an annotation.
|
protected abstract TypeDescription |
FieldProxy.Binder.AccessType.proxyType(MethodDescription getterMethod,
MethodDescription setterMethod)
Locates the type to be implemented by a field accessor proxy.
|
TypeDescription |
Default.Binder.TypeLocator.resolve(TypeDescription.Generic parameterType)
Resolves the target type.
|
TypeDescription |
Default.Binder.TypeLocator.ForParameterType.resolve(TypeDescription.Generic parameterType) |
TypeDescription |
Default.Binder.TypeLocator.ForType.resolve(TypeDescription.Generic parameterType) |
TypeDescription |
Super.Binder.TypeLocator.resolve(TypeDescription instrumentedType,
TypeDescription.Generic parameterType)
Resolves the target type.
|
TypeDescription |
Super.Binder.TypeLocator.ForInstrumentedType.resolve(TypeDescription instrumentedType,
TypeDescription.Generic parameterType) |
TypeDescription |
Super.Binder.TypeLocator.ForParameterType.resolve(TypeDescription instrumentedType,
TypeDescription.Generic parameterType) |
TypeDescription |
Super.Binder.TypeLocator.ForType.resolve(TypeDescription instrumentedType,
TypeDescription.Generic parameterType) |
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 static Super.Binder.TypeLocator |
Super.Binder.TypeLocator.ForType.of(TypeDescription typeDescription)
Resolves a type locator based upon an annotation value.
|
protected static Default.Binder.TypeLocator |
Default.Binder.TypeLocator.ForType.of(TypeDescription typeDescription)
Resolves a type locator based upon an annotation value.
|
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. |
TypeDescription |
Super.Binder.TypeLocator.resolve(TypeDescription instrumentedType,
TypeDescription.Generic parameterType)
Resolves the target type.
|
TypeDescription |
Super.Binder.TypeLocator.ForInstrumentedType.resolve(TypeDescription instrumentedType,
TypeDescription.Generic parameterType) |
TypeDescription |
Super.Binder.TypeLocator.ForParameterType.resolve(TypeDescription instrumentedType,
TypeDescription.Generic parameterType) |
TypeDescription |
Super.Binder.TypeLocator.ForType.resolve(TypeDescription instrumentedType,
TypeDescription.Generic parameterType) |
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.
|
ForType(TypeDescription typeDescription)
Creates a new type locator for a given type.
|
ForType(TypeDescription typeDescription)
Creates a new type locator for a given 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.
|
Redirection(TypeDescription forwardingType,
MethodDescription sourceMethod,
Assigner assigner,
boolean serializableProxy)
Creates a new redirection.
|
RedirectionProxy(TypeDescription morphingType,
TypeDescription instrumentedType,
Implementation.SpecialMethodInvocation specialMethodInvocation,
Assigner assigner,
boolean serializableProxy)
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.of(TypeDescription typeDescription)
Creates a type creation for the given type.
|
Constructor and Description |
---|
TypeCreation(TypeDescription typeDescription)
Constructs a new type creation.
|
Constructor and Description |
---|
TypeCasting(TypeDescription typeDescription)
Creates a new type casting.
|
Modifier and Type | Method and Description |
---|---|
static ArrayAccess |
ArrayAccess.of(TypeDescription componentType)
Locates an array accessor by the array's component type.
|
Constructor and Description |
---|
ForReferenceType(TypeDescription referenceType)
Creates a new array creator for a reference type.
|
Modifier and Type | Method and Description |
---|---|
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.OfGenericMethod.dynamic(String methodName,
TypeDescription returnType,
List<? extends TypeDescription> methodType,
List<?> arguments) |
StackManipulation |
MethodInvocation.Invocation.dynamic(String methodName,
TypeDescription returnType,
List<? extends TypeDescription> methodType,
List<?> arguments) |
StackManipulation |
MethodVariableAccess.MethodLoading.TypeCastingHandler.ofIndex(TypeDescription parameterType,
int index)
Yields a stack transformation to transform the given argument of the method for which the arguments are loaded onto the operand stack.
|
StackManipulation |
MethodVariableAccess.MethodLoading.TypeCastingHandler.NoOp.ofIndex(TypeDescription parameterType,
int index) |
StackManipulation |
MethodVariableAccess.MethodLoading.TypeCastingHandler.ForBridgeTarget.ofIndex(TypeDescription parameterType,
int index) |
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.OfGenericMethod.special(TypeDescription invocationTarget) |
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.OfGenericMethod.virtual(TypeDescription invocationTarget) |
StackManipulation |
MethodInvocation.Invocation.virtual(TypeDescription invocationTarget) |
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.OfGenericMethod.dynamic(String methodName,
TypeDescription returnType,
List<? extends TypeDescription> methodType,
List<?> arguments) |
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.InDefinedShape 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.
|
OfGenericMethod(TypeDescription targetType,
MethodInvocation.WithImplicitInvocationTargetType invocation)
Creates a generic method invocation.
|
Modifier and Type | Class and Description |
---|---|
class |
HasSuperTypeMatcher<T extends TypeDescription>
An element matcher that matches a super type.
|
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.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.hasGenericSuperType(ElementMatcher<? super TypeDescription.Generic> matcher)
Matches any type description that declares a super type that matches the provided matcher.
|
static <T extends TypeDescription> |
ElementMatchers.hasSuperType(ElementMatcher<? super TypeDescription> matcher)
Matches any type description that declares a super type that matches the provided matcher.
|
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 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.isInterface()
Matches a
TypeDescription that is an interface. |
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 type)
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 type)
Matches any type description that is a super type of the given type.
|
Modifier and Type | Method and Description |
---|---|
static <T extends AnnotationDescription> |
ElementMatchers.annotationType(TypeDescription type)
Matches if an annotation is of a given type.
|
static <T extends MethodDescription> |
ElementMatchers.canThrow(TypeDescription exceptionType)
Matches a
MethodDescription by its capability to throw a given
checked exception. |
static <T extends MethodDescription> |
ElementMatchers.declaresException(TypeDescription exceptionType)
Matches a method that declares the given generic exception type as a (erased) exception type.
|
static <T extends FieldDescription> |
ElementMatchers.fieldType(TypeDescription fieldType)
Matches a field's raw type against the provided matcher.
|
static <T extends TypeDescription> |
ElementMatchers.inheritsAnnotation(TypeDescription type)
Matches any annotations by their type on a type that declared these annotations or inherited them from its
super classes.
|
static <T extends AnnotatedCodeElement> |
ElementMatchers.isAnnotatedWith(TypeDescription type)
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 TypeDescription> |
ElementMatchers.isSubTypeOf(TypeDescription type)
Matches any type description that is a subtype of the given type.
|
static <T extends TypeDescription> |
ElementMatchers.isSuperTypeOf(TypeDescription type)
Matches any type description that is a super type of the given type.
|
static <T extends ByteCodeElement> |
ElementMatchers.isVisibleTo(TypeDescription type)
Matches a
ByteCodeElement that is visible to a given
TypeDescription . |
static <T extends TypeDescription.Generic> |
ElementMatchers.rawType(TypeDescription type)
Matches a generic type's raw type against the provided raw type.
|
static <T extends Iterable<? extends TypeDescription.Generic>> |
ElementMatchers.rawTypes(TypeDescription... type)
Matches an iteration of generic types' erasures against the provided raw types.
|
ElementMatcher<? super T> |
LatentMatcher.resolve(TypeDescription typeDescription)
Resolves the element matcher this instance represents for the supplied type description.
|
ElementMatcher<? super S> |
LatentMatcher.Resolved.resolve(TypeDescription typeDescription) |
ElementMatcher<? super FieldDescription> |
LatentMatcher.ForFieldToken.resolve(TypeDescription typeDescription) |
ElementMatcher<? super MethodDescription> |
LatentMatcher.ForMethodToken.resolve(TypeDescription typeDescription) |
ElementMatcher<? super S> |
LatentMatcher.Compound.resolve(TypeDescription typeDescription) |
static <T extends MethodDescription> |
ElementMatchers.returns(TypeDescription type)
Matches
MethodDescription s that return a given erasure type. |
static <T extends MethodDescription> |
ElementMatchers.takesArgument(int index,
TypeDescription type)
Matches
MethodDescription s that define a given generic type as a parameter at the given index. |
static <T extends MethodDescription> |
ElementMatchers.takesArguments(TypeDescription... type)
Matches a method description that takes the provided raw arguments.
|
Modifier and Type | Method and Description |
---|---|
static <T extends AnnotationDescription> |
ElementMatchers.annotationType(ElementMatcher<? super TypeDescription> matcher)
Matches if an annotation's type matches the supplied matcher.
|
static <T extends FieldDescription> |
ElementMatchers.fieldType(ElementMatcher<? super TypeDescription> matcher)
Matches a field's raw type against the provided matcher.
|
static <T extends TypeDescription> |
ElementMatchers.hasSuperType(ElementMatcher<? super TypeDescription> matcher)
Matches any type description that declares a super type that matches the provided matcher.
|
static <T extends ParameterDescription> |
ElementMatchers.hasType(ElementMatcher<? super TypeDescription> matcher)
Matches a parameter's type by the given matcher.
|
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 ClassLoader> |
ElementMatchers.ofType(ElementMatcher<? super TypeDescription> matcher)
Matches a class loader's type unless it is the bootstrap class loader which is never matched.
|
static <T extends TypeDescription.Generic> |
ElementMatchers.rawType(ElementMatcher<? super TypeDescription> matcher)
Converts a matcher for a type description into a matcher for a raw type of the matched generic type against the given matcher.
|
static <T extends Iterable<? extends TypeDescription.Generic>> |
ElementMatchers.rawTypes(ElementMatcher<? super Iterable<? extends TypeDescription>> matcher)
Applies the provided matcher to an iteration og generic types' generic types.
|
static <T extends Iterable<? extends TypeDescription.Generic>> |
ElementMatchers.rawTypes(Iterable<? extends TypeDescription> types)
Matches an iteration of generic types' erasures against the provided raw types.
|
static <T extends MethodDescription> |
ElementMatchers.returns(ElementMatcher<? super TypeDescription> matcher)
Matches a method's return type's erasure by the given matcher.
|
static <T extends MethodDescription> |
ElementMatchers.takesArguments(Iterable<? extends TypeDescription> types)
Matches a method description that takes the provided raw arguments.
|
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> matcher)
Creates a new matcher for an annotation description's type.
|
CollectionRawTypeMatcher(ElementMatcher<? super Iterable<? extends TypeDescription>> matcher)
Creates a new raw type matcher.
|
InstanceTypeMatcher(ElementMatcher<? super TypeDescription> matcher)
Creates a new instance type matcher.
|
RawTypeMatcher(ElementMatcher<? super TypeDescription> matcher)
Creates a new raw type matcher.
|
Modifier and Type | Class and Description |
---|---|
protected static class |
TypePool.Default.LazyTypeDescription
A type description that looks up any referenced
ByteCodeElement or
AnnotationDescription by querying a type pool at lookup time. |
protected class |
TypePool.Default.WithLazyResolution.LazyTypeDescription
A lazy type description that resolves any property that is not the name only when requested.
|
protected static class |
TypePool.LazyFacade.LazyTypeDescription
A description of a type that delegates to another type pool once a property that is not the name is resolved.
|
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.Default.LazyTypeDescription.GenericTypeToken.ForPrimitiveType.LazyPrimitiveType.asErasure() |
TypeDescription |
TypePool.Default.LazyTypeDescription.GenericTypeToken.Resolution.Raw.RawAnnotatedType.asErasure() |
TypeDescription |
TypePool.Default.LazyTypeDescription.GenericTypeToken.ForParameterizedType.Nested.LazyParameterizedType.asErasure() |
TypeDescription |
TypePool.Default.LazyTypeDescription.GenericTypeToken.ForParameterizedType.LazyParameterizedType.asErasure() |
protected TypeDescription |
TypePool.Default.WithLazyResolution.LazyTypeDescription.delegate() |
protected TypeDescription |
TypePool.LazyFacade.LazyTypeDescription.delegate() |
TypeDescription |
TypePool.Default.LazyTypeDescription.getDeclaringType() |
TypeDescription |
TypePool.Default.LazyTypeDescription.getEnclosingType() |
TypeDescription |
TypePool.Default.LazyTypeDescription.TypeContainment.getEnclosingType(TypePool typePool)
Returns the enclosing type or
null if no such type exists. |
TypeDescription |
TypePool.Default.LazyTypeDescription.TypeContainment.SelfContained.getEnclosingType(TypePool typePool) |
TypeDescription |
TypePool.Default.LazyTypeDescription.TypeContainment.WithinType.getEnclosingType(TypePool typePool) |
TypeDescription |
TypePool.Default.LazyTypeDescription.TypeContainment.WithinMethod.getEnclosingType(TypePool typePool) |
TypeDescription |
TypePool.AbstractBase.RawEnumerationValue.LazyEnumerationDescription.getEnumerationType() |
TypeDescription |
TypePool.Resolution.resolve()
Resolves this resolution to a
TypeDescription . |
TypeDescription |
TypePool.Resolution.Simple.resolve() |
TypeDescription |
TypePool.Resolution.Illegal.resolve() |
TypeDescription |
TypePool.AbstractBase.ArrayTypeResolution.resolve() |
TypeDescription |
TypePool.AbstractBase.RawTypeValue.resolve() |
TypeDescription |
TypePool.Default.WithLazyResolution.LazyResolution.resolve() |
TypeDescription |
TypePool.LazyFacade.LazyResolution.resolve() |
protected TypeDescription |
TypePool.Default.TypeExtractor.toTypeDescription()
Creates a type description from all data that is currently collected.
|
Modifier and Type | Method and Description |
---|---|
TypeList.Generic |
TypePool.Default.LazyTypeDescription.GenericTypeToken.Resolution.Raw.resolveInterfaceTypes(List<String> interfaceTypeDescriptors,
TypePool typePool,
Map<Integer,Map<String,List<TypePool.Default.LazyTypeDescription.AnnotationToken>>> annotationTokens,
TypeDescription definingType) |
TypeList.Generic |
TypePool.Default.LazyTypeDescription.GenericTypeToken.Resolution.Malformed.resolveInterfaceTypes(List<String> interfaceTypeDescriptors,
TypePool typePool,
Map<Integer,Map<String,List<TypePool.Default.LazyTypeDescription.AnnotationToken>>> annotationTokens,
TypeDescription definingType) |
TypeList.Generic |
TypePool.Default.LazyTypeDescription.GenericTypeToken.Resolution.ForType.resolveInterfaceTypes(List<String> interfaceTypeDescriptors,
TypePool typePool,
Map<Integer,Map<String,List<TypePool.Default.LazyTypeDescription.AnnotationToken>>> annotationTokens,
TypeDescription definingType)
Resolves the generic interface types of the represented type.
|
TypeList.Generic |
TypePool.Default.LazyTypeDescription.GenericTypeToken.Resolution.ForType.Tokenized.resolveInterfaceTypes(List<String> interfaceTypeDescriptors,
TypePool typePool,
Map<Integer,Map<String,List<TypePool.Default.LazyTypeDescription.AnnotationToken>>> annotationTokens,
TypeDescription definingType) |
TypeDescription.Generic |
TypePool.Default.LazyTypeDescription.GenericTypeToken.Resolution.Raw.resolveSuperClass(String superClassDescriptor,
TypePool typePool,
Map<String,List<TypePool.Default.LazyTypeDescription.AnnotationToken>> annotationTokens,
TypeDescription definingType) |
TypeDescription.Generic |
TypePool.Default.LazyTypeDescription.GenericTypeToken.Resolution.Malformed.resolveSuperClass(String superClassDescriptor,
TypePool typePool,
Map<String,List<TypePool.Default.LazyTypeDescription.AnnotationToken>> annotationTokens,
TypeDescription definingType) |
TypeDescription.Generic |
TypePool.Default.LazyTypeDescription.GenericTypeToken.Resolution.ForType.resolveSuperClass(String superClassDescriptor,
TypePool typePool,
Map<String,List<TypePool.Default.LazyTypeDescription.AnnotationToken>> annotationTokens,
TypeDescription definingType)
Resolves the generic super type of the represented type.
|
TypeDescription.Generic |
TypePool.Default.LazyTypeDescription.GenericTypeToken.Resolution.ForType.Tokenized.resolveSuperClass(String superClassDescriptor,
TypePool typePool,
Map<String,List<TypePool.Default.LazyTypeDescription.AnnotationToken>> annotationTokens,
TypeDescription definingType) |
Constructor and Description |
---|
LazyPrimitiveType(TypePool typePool,
String typePath,
Map<String,List<TypePool.Default.LazyTypeDescription.AnnotationToken>> annotationTokens,
TypeDescription typeDescription)
Creates a new lazy primitive type.
|
RawAnnotatedType(TypePool typePool,
String typePath,
Map<String,List<TypePool.Default.LazyTypeDescription.AnnotationToken>> annotationTokens,
TypeDescription typeDescription)
Creates a new raw annotated type.
|
Simple(TypeDescription typeDescription)
Creates a new successful resolution of a given type description.
|
Constructor and Description |
---|
Explicit(Map<String,TypeDescription> types)
Creates a new explicit type pool without a parent.
|
Explicit(TypePool parent,
Map<String,TypeDescription> types)
Creates a new explicit type pool.
|
Modifier and Type | Method and Description |
---|---|
TypeDescription |
JavaConstant.MethodHandle.getOwnerType()
Returns the owner type of this instance.
|
TypeDescription |
JavaConstant.MethodType.getReturnType()
Returns the return type of this method type.
|
TypeDescription |
JavaConstant.MethodHandle.getReturnType()
Returns the return type represented by this instance.
|
TypeDescription |
JavaConstant.getType()
Returns a description of the type of the represented instance or at least a stub.
|
TypeDescription |
JavaConstant.MethodType.getType() |
TypeDescription |
JavaConstant.MethodHandle.getType() |
TypeDescription |
JavaType.getTypeStub()
Returns at least a stub representing this type where the stub does not define any methods or fields.
|
Modifier and Type | Method and Description |
---|---|
static JavaConstant.MethodType |
JavaConstant.MethodType.of(TypeDescription returnType,
List<? extends TypeDescription> parameterTypes)
Returns a method type description of the given return type and parameter types.
|
static JavaConstant.MethodType |
JavaConstant.MethodType.ofConstant(TypeDescription typeDescription)
Returns a method type for the given constant type.
|
static JavaConstant.MethodHandle |
JavaConstant.MethodHandle.ofSpecial(MethodDescription.InDefinedShape 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 JavaConstant.MethodType |
JavaConstant.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(JavaConstant.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(JavaConstant.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–2016. All rights reserved.