Package net.bytebuddy.build
Interface Plugin.Engine.Listener
-
- All Superinterfaces:
Plugin.Engine.ErrorHandler
- All Known Implementing Classes:
ByteBuddyMojo.TransformationLogger
,Plugin.Engine.Listener.Adapter
,Plugin.Engine.Listener.Compound
,Plugin.Engine.Listener.ForErrorHandler
,Plugin.Engine.Listener.NoOp
,Plugin.Engine.Listener.StreamWriting
,Plugin.Engine.Listener.WithErrorsOnly
,Plugin.Engine.Listener.WithTransformationsOnly
- Enclosing interface:
- Plugin.Engine
public static interface Plugin.Engine.Listener extends Plugin.Engine.ErrorHandler
A listener that is invoked upon any event during a plugin engine application.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static class
Plugin.Engine.Listener.Adapter
An adapter that implements all methods non-operational.static class
Plugin.Engine.Listener.Compound
A compound listener.static class
Plugin.Engine.Listener.ForErrorHandler
A listener decorator that forwards events to an error handler if they are applicable.static class
Plugin.Engine.Listener.NoOp
A non-operational listener.static class
Plugin.Engine.Listener.StreamWriting
A listener that forwards significant events of a plugin engine application to aPrintStream
.static class
Plugin.Engine.Listener.WithErrorsOnly
A decorator for another listener to only print error events.static class
Plugin.Engine.Listener.WithTransformationsOnly
A decorator for another listener to only print transformation and error events.-
Nested classes/interfaces inherited from interface net.bytebuddy.build.Plugin.Engine.ErrorHandler
Plugin.Engine.ErrorHandler.Enforcing, Plugin.Engine.ErrorHandler.Failing
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
onComplete(TypeDescription typeDescription)
Invoked upon completing handling a type that was either transformed or ignored.void
onDiscovery(java.lang.String typeName)
Invoked upon discovering a type but prior to its resolution.void
onIgnored(TypeDescription typeDescription, java.util.List<Plugin> plugins)
Invoked if one or more plugins did not transform a type.void
onIgnored(TypeDescription typeDescription, Plugin plugin)
Invoked if a type description is ignored by a given plugin.void
onTransformation(TypeDescription typeDescription, java.util.List<Plugin> plugins)
Invoked after a type was transformed using at least one plugin.void
onTransformation(TypeDescription typeDescription, Plugin plugin)
Invoked after a type was transformed using a specific plugin.-
Methods inherited from interface net.bytebuddy.build.Plugin.Engine.ErrorHandler
onError, onError, onError, onError, onLiveInitializer, onManifest, onResource, onUnresolved
-
-
-
-
Method Detail
-
onDiscovery
void onDiscovery(java.lang.String typeName)
Invoked upon discovering a type but prior to its resolution.- Parameters:
typeName
- The name of the discovered type.
-
onTransformation
void onTransformation(TypeDescription typeDescription, Plugin plugin)
Invoked after a type was transformed using a specific plugin.- Parameters:
typeDescription
- The type being transformed.plugin
- The plugin that was applied.
-
onTransformation
void onTransformation(TypeDescription typeDescription, java.util.List<Plugin> plugins)
Invoked after a type was transformed using at least one plugin.- Parameters:
typeDescription
- The type being transformed.plugins
- A list of plugins that were applied.
-
onIgnored
void onIgnored(TypeDescription typeDescription, Plugin plugin)
Invoked if a type description is ignored by a given plugin. This callback is not invoked, if the ignore type matcher excluded a type from transformation.- Parameters:
typeDescription
- The type being transformed.plugin
- The plugin that ignored the given type.
-
onIgnored
void onIgnored(TypeDescription typeDescription, java.util.List<Plugin> plugins)
Invoked if one or more plugins did not transform a type. This callback is also invoked if an ignore matcher excluded a type from transformation.- Parameters:
typeDescription
- The type being transformed.plugins
- the plugins that ignored the type.
-
onComplete
void onComplete(TypeDescription typeDescription)
Invoked upon completing handling a type that was either transformed or ignored.- Parameters:
typeDescription
- The type that was transformed.
-
-