Package | Description |
---|---|
net.bytebuddy.agent.builder |
An agent builder is used to easily implement load-time class-transformations using a Java agent.
|
net.bytebuddy.build |
A package for types that allow for applying Byte Buddy transformation during a build process.
|
Modifier and Type | Method and Description |
---|---|
static AgentBuilder |
AgentBuilder.Default.of(ClassFileVersion classFileVersion,
Plugin... plugin)
Creates an
AgentBuilder that realizes the provided build plugins. |
static AgentBuilder |
AgentBuilder.Default.of(EntryPoint entryPoint,
ClassFileVersion classFileVersion,
Plugin... plugin)
Creates an
AgentBuilder that realizes the provided build plugins. |
static AgentBuilder |
AgentBuilder.Default.of(EntryPoint entryPoint,
Plugin... plugin)
Creates an
AgentBuilder that realizes the provided build plugins. |
static AgentBuilder |
AgentBuilder.Default.of(Plugin... plugin)
Creates an
AgentBuilder that realizes the provided build plugins. |
Modifier and Type | Method and Description |
---|---|
static AgentBuilder |
AgentBuilder.Default.of(ClassFileVersion classFileVersion,
List<? extends Plugin> plugins)
Creates an
AgentBuilder that realizes the provided build plugins. |
static AgentBuilder |
AgentBuilder.Default.of(EntryPoint entryPoint,
ClassFileVersion classFileVersion,
List<? extends Plugin> plugins)
Creates an
AgentBuilder that realizes the provided build plugins. |
static AgentBuilder |
AgentBuilder.Default.of(EntryPoint entryPoint,
List<? extends Plugin> plugins)
Creates an
AgentBuilder that realizes the provided build plugins. |
static AgentBuilder |
AgentBuilder.Default.of(List<? extends Plugin> plugins)
Creates an
AgentBuilder that realizes the provided build plugins. |
Constructor and Description |
---|
ForBuildPlugin(Plugin plugin)
Creates a new transformer for a build
Plugin . |
Modifier and Type | Interface and Description |
---|---|
static interface |
Plugin.WithPreprocessor
A plugin that applies a preprocessor, i.e.
|
Modifier and Type | Class and Description |
---|---|
class |
CachedReturnPlugin
A plugin that caches the return value of a method in a synthetic field.
|
class |
HashCodeAndEqualsPlugin
A build tool plugin that adds
Object.hashCode() and Object.equals(Object) methods to a class if the
HashCodeAndEqualsPlugin.Enhance annotation is present and no explicit method declaration was added. |
static class |
HashCodeAndEqualsPlugin.WithNonNullableFields
A version of the
HashCodeAndEqualsPlugin that assumes that all fields are non-nullable unless they are explicitly marked. |
static class |
Plugin.ForElementMatcher
An abstract base for a
Plugin that matches types by a given ElementMatcher . |
static class |
Plugin.NoOp
A non-operational plugin that does not instrument any type.
|
class |
ToStringPlugin
A build tool plugin that adds a
Object.toString() and method to a class if the ToStringPlugin.Enhance annotation is present and no
explicit method declaration was added. |
Modifier and Type | Method and Description |
---|---|
Plugin |
Plugin.Factory.UsingReflection.Instantiator.instantiate()
Instantiates the represented plugin.
|
Plugin |
Plugin.Factory.UsingReflection.Instantiator.Unresolved.instantiate()
Instantiates the represented plugin.
|
Plugin |
Plugin.Factory.UsingReflection.Instantiator.Resolved.instantiate()
Instantiates the represented plugin.
|
Plugin |
ToStringPlugin.make()
Returns a plugin that can be used for a transformation and which is subsequently closed.
|
Plugin |
Plugin.Factory.make()
Returns a plugin that can be used for a transformation and which is subsequently closed.
|
Plugin |
Plugin.Factory.Simple.make()
Returns a plugin that can be used for a transformation and which is subsequently closed.
|
Plugin |
Plugin.Factory.UsingReflection.make()
Returns a plugin that can be used for a transformation and which is subsequently closed.
|
Plugin |
Plugin.NoOp.make()
Returns a plugin that can be used for a transformation and which is subsequently closed.
|
Plugin |
HashCodeAndEqualsPlugin.make()
Returns a plugin that can be used for a transformation and which is subsequently closed.
|
Plugin |
CachedReturnPlugin.make()
Returns a plugin that can be used for a transformation and which is subsequently closed.
|
Modifier and Type | Method and Description |
---|---|
void |
Plugin.Engine.ErrorHandler.onError(Plugin plugin,
Throwable throwable)
Invoked at the end of the build if a plugin could not be closed.
|
void |
Plugin.Engine.ErrorHandler.Failing.onError(Plugin plugin,
Throwable throwable)
Invoked at the end of the build if a plugin could not be closed.
|
void |
Plugin.Engine.ErrorHandler.Enforcing.onError(Plugin plugin,
Throwable throwable)
Invoked at the end of the build if a plugin could not be closed.
|
void |
Plugin.Engine.ErrorHandler.Compound.onError(Plugin plugin,
Throwable throwable)
Invoked at the end of the build if a plugin could not be closed.
|
void |
Plugin.Engine.Listener.NoOp.onError(Plugin plugin,
Throwable throwable)
Invoked at the end of the build if a plugin could not be closed.
|
void |
Plugin.Engine.Listener.Adapter.onError(Plugin plugin,
Throwable throwable)
Invoked at the end of the build if a plugin could not be closed.
|
void |
Plugin.Engine.Listener.StreamWriting.onError(Plugin plugin,
Throwable throwable)
Invoked at the end of the build if a plugin could not be closed.
|
void |
Plugin.Engine.Listener.WithTransformationsOnly.onError(Plugin plugin,
Throwable throwable) |
void |
Plugin.Engine.Listener.WithErrorsOnly.onError(Plugin plugin,
Throwable throwable) |
void |
Plugin.Engine.Listener.ForErrorHandler.onError(Plugin plugin,
Throwable throwable) |
void |
Plugin.Engine.Listener.Compound.onError(Plugin plugin,
Throwable throwable)
Invoked at the end of the build if a plugin could not be closed.
|
void |
Plugin.Engine.ErrorHandler.onError(TypeDescription typeDescription,
Plugin plugin,
Throwable throwable)
Invoked if an error occured during a plugin's application on a given type.
|
void |
Plugin.Engine.ErrorHandler.Enforcing.onError(TypeDescription typeDescription,
Plugin plugin,
Throwable throwable)
Invoked if an error occured during a plugin's application on a given type.
|
void |
Plugin.Engine.ErrorHandler.Compound.onError(TypeDescription typeDescription,
Plugin plugin,
Throwable throwable)
Invoked if an error occured during a plugin's application on a given type.
|
void |
Plugin.Engine.Listener.NoOp.onError(TypeDescription typeDescription,
Plugin plugin,
Throwable throwable)
Invoked if an error occured during a plugin's application on a given type.
|
void |
Plugin.Engine.Listener.Adapter.onError(TypeDescription typeDescription,
Plugin plugin,
Throwable throwable)
Invoked if an error occured during a plugin's application on a given type.
|
void |
Plugin.Engine.Listener.StreamWriting.onError(TypeDescription typeDescription,
Plugin plugin,
Throwable throwable)
Invoked if an error occured during a plugin's application on a given type.
|
void |
Plugin.Engine.Listener.WithTransformationsOnly.onError(TypeDescription typeDescription,
Plugin plugin,
Throwable throwable) |
void |
Plugin.Engine.Listener.WithErrorsOnly.onError(TypeDescription typeDescription,
Plugin plugin,
Throwable throwable) |
void |
Plugin.Engine.Listener.ForErrorHandler.onError(TypeDescription typeDescription,
Plugin plugin,
Throwable throwable) |
void |
Plugin.Engine.Listener.Compound.onError(TypeDescription typeDescription,
Plugin plugin,
Throwable throwable)
Invoked if an error occured during a plugin's application on a given type.
|
void |
Plugin.Engine.Listener.onIgnored(TypeDescription typeDescription,
Plugin plugin)
Invoked if a type description is ignored by a given plugin.
|
void |
Plugin.Engine.Listener.NoOp.onIgnored(TypeDescription typeDescription,
Plugin plugin)
Invoked if a type description is ignored by a given plugin.
|
void |
Plugin.Engine.Listener.Adapter.onIgnored(TypeDescription typeDescription,
Plugin plugin)
Invoked if a type description is ignored by a given plugin.
|
void |
Plugin.Engine.Listener.StreamWriting.onIgnored(TypeDescription typeDescription,
Plugin plugin)
Invoked if a type description is ignored by a given plugin.
|
void |
Plugin.Engine.Listener.Compound.onIgnored(TypeDescription typeDescription,
Plugin plugin)
Invoked if a type description is ignored by a given plugin.
|
void |
Plugin.Engine.Listener.onTransformation(TypeDescription typeDescription,
Plugin plugin)
Invoked after a type was transformed using a specific plugin.
|
void |
Plugin.Engine.Listener.NoOp.onTransformation(TypeDescription typeDescription,
Plugin plugin)
Invoked after a type was transformed using a specific plugin.
|
void |
Plugin.Engine.Listener.Adapter.onTransformation(TypeDescription typeDescription,
Plugin plugin)
Invoked after a type was transformed using a specific plugin.
|
void |
Plugin.Engine.Listener.StreamWriting.onTransformation(TypeDescription typeDescription,
Plugin plugin)
Invoked after a type was transformed using a specific plugin.
|
void |
Plugin.Engine.Listener.WithTransformationsOnly.onTransformation(TypeDescription typeDescription,
Plugin plugin) |
void |
Plugin.Engine.Listener.Compound.onTransformation(TypeDescription typeDescription,
Plugin plugin)
Invoked after a type was transformed using a specific plugin.
|
Modifier and Type | Method and Description |
---|---|
void |
Plugin.Engine.Listener.onIgnored(TypeDescription typeDescription,
List<Plugin> plugins)
Invoked if one or more plugins did not transform a type.
|
void |
Plugin.Engine.Listener.NoOp.onIgnored(TypeDescription typeDescription,
List<Plugin> plugins)
Invoked if one or more plugins did not transform a type.
|
void |
Plugin.Engine.Listener.Adapter.onIgnored(TypeDescription typeDescription,
List<Plugin> plugins)
Invoked if one or more plugins did not transform a type.
|
void |
Plugin.Engine.Listener.Compound.onIgnored(TypeDescription typeDescription,
List<Plugin> plugins)
Invoked if one or more plugins did not transform a type.
|
void |
Plugin.Engine.Listener.onTransformation(TypeDescription typeDescription,
List<Plugin> plugins)
Invoked after a type was transformed using at least one plugin.
|
void |
Plugin.Engine.Listener.NoOp.onTransformation(TypeDescription typeDescription,
List<Plugin> plugins)
Invoked after a type was transformed using at least one plugin.
|
void |
Plugin.Engine.Listener.Adapter.onTransformation(TypeDescription typeDescription,
List<Plugin> plugins)
Invoked after a type was transformed using at least one plugin.
|
void |
Plugin.Engine.Listener.WithTransformationsOnly.onTransformation(TypeDescription typeDescription,
List<Plugin> plugins) |
void |
Plugin.Engine.Listener.Compound.onTransformation(TypeDescription typeDescription,
List<Plugin> plugins)
Invoked after a type was transformed using at least one plugin.
|
Constructor and Description |
---|
Simple(Plugin plugin)
Creates a simple plugin factory.
|
Constructor and Description |
---|
Resolved(Constructor<? extends Plugin> constructor,
List<?> arguments)
Creates a new resolved constructor.
|
Unresolved(Class<? extends Plugin> type)
Creates a new unresolved constructor.
|
UsingReflection(Class<? extends Plugin> type)
Creates a plugin factory that uses reflection for creating a plugin.
|
UsingReflection(Class<? extends Plugin> type,
List<Plugin.Factory.UsingReflection.ArgumentResolver> argumentResolvers)
Creates a plugin factory that uses reflection for creating a plugin.
|
Copyright © 2014–2020. All rights reserved.