Class RunMojo

  • All Implemented Interfaces:
    org.apache.maven.plugin.ContextEnabled, org.apache.maven.plugin.Mojo

    @Mojo(name="run",
          requiresProject=true,
          defaultPhase=VALIDATE,
          requiresDependencyResolution=TEST)
    @Execute(phase=TEST_COMPILE)
    public class RunMojo
    extends AbstractRunMojo
    Run an executable archive application.
    Author:
    Phillip Webb, Stephane Nicoll
    • Constructor Detail

      • RunMojo

        public RunMojo()
    • Method Detail

      • runWithForkedJvm

        protected void runWithForkedJvm​(java.util.List<java.lang.String> args)
                                 throws org.apache.maven.plugin.MojoExecutionException
        Description copied from class: AbstractRunMojo
        Run with a forked VM, using the specified command line arguments.
        Specified by:
        runWithForkedJvm in class AbstractRunMojo
        Parameters:
        args - the arguments (JVM arguments and application arguments)
        Throws:
        org.apache.maven.plugin.MojoExecutionException - in case of MOJO execution errors
      • runWithMavenJvm

        protected void runWithMavenJvm​(java.lang.String startClassName,
                                       java.lang.String... arguments)
                                throws org.apache.maven.plugin.MojoExecutionException
        Description copied from class: AbstractRunMojo
        Run with the current VM, using the specified arguments.
        Specified by:
        runWithMavenJvm in class AbstractRunMojo
        Parameters:
        startClassName - the class to run
        arguments - the class arguments
        Throws:
        org.apache.maven.plugin.MojoExecutionException - in case of MOJO execution errors