Class ByteBuddyMojo.ForLifecycleTypes

java.lang.Object
org.apache.maven.plugin.AbstractMojo
net.bytebuddy.build.maven.ByteBuddyMojo
net.bytebuddy.build.maven.ByteBuddyMojo.ForLifecycleTypes
All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled, org.apache.maven.plugin.Mojo
Direct Known Subclasses:
ByteBuddyMojo.ForLifecycleTypes.ForProductionTypes, ByteBuddyMojo.ForLifecycleTypes.ForTestTypes
Enclosing class:
ByteBuddyMojo

public abstract static class ByteBuddyMojo.ForLifecycleTypes extends ByteBuddyMojo
A version of the plugin that is bound to Maven's lifecycle.
  • Field Details

    • context

      @MaybeNull @Component public org.sonatype.plexus.build.incremental.BuildContext context
      The build context to support incremental builds.
    • incremental

      @Parameter(defaultValue="false", required=true) public boolean incremental
      Determines if plugins are attempted to be built incrementally.
  • Constructor Details

    • ForLifecycleTypes

      public ForLifecycleTypes()
  • Method Details

    • getOutputDirectory

      protected abstract String getOutputDirectory()
      Returns the output directory to search for class files.
      Returns:
      The output directory to search for class files.
    • getSourceDirectory

      @MaybeNull protected abstract String getSourceDirectory()
      Returns the source directory that determines the class files to process.
      Returns:
      The source directory that serves as an input for the transformation.
    • apply

      protected void apply(List<ByteBuddyMojo.Transformer> transformers, List<String> elements, Map<ByteBuddyMojo.Coordinate,String> coordinates) throws org.apache.maven.plugin.MojoExecutionException, IOException
      Description copied from class: ByteBuddyMojo
      Applies this mojo for the given setup.
      Specified by:
      apply in class ByteBuddyMojo
      Parameters:
      transformers - The transformers to apply.
      elements - The class path elements to consider.
      coordinates - Versions for managed dependencies.
      Throws:
      org.apache.maven.plugin.MojoExecutionException - If the plugin fails due to a user error.
      IOException - If an I/O exception occurs.