Class DefaultInvocationResult

java.lang.Object
org.apache.maven.shared.invoker.DefaultInvocationResult
All Implemented Interfaces:
InvocationResult

public final class DefaultInvocationResult extends Object implements InvocationResult
Describes the result of a Maven invocation.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    private org.apache.maven.shared.utils.cli.CommandLineException
    The exception that prevented to execute the command line, will be null if Maven could be successfully started.
    private int
    The exit code reported by the Maven invocation.
  • Constructor Summary

    Constructors
    Constructor
    Description
    Creates a new invocation result
  • Method Summary

    Modifier and Type
    Method
    Description
    org.apache.maven.shared.utils.cli.CommandLineException
    Getter for the field executionException.
    int
    Getter for the field exitCode.
    (package private) void
    setExecutionException(org.apache.maven.shared.utils.cli.CommandLineException executionException)
    Sets the exception that prevented to execute the command line.
    (package private) void
    setExitCode(int exitCode)
    Sets the exit code reported by the Maven invocation.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • executionException

      private org.apache.maven.shared.utils.cli.CommandLineException executionException
      The exception that prevented to execute the command line, will be null if Maven could be successfully started.
    • exitCode

      private int exitCode
      The exit code reported by the Maven invocation.
  • Constructor Details

    • DefaultInvocationResult

      DefaultInvocationResult()
      Creates a new invocation result
  • Method Details

    • getExitCode

      public int getExitCode()

      Getter for the field exitCode.

      Specified by:
      getExitCode in interface InvocationResult
      Returns:
      a int.
    • getExecutionException

      public org.apache.maven.shared.utils.cli.CommandLineException getExecutionException()

      Getter for the field executionException.

      Specified by:
      getExecutionException in interface InvocationResult
      Returns:
      a CommandLineException object.
    • setExitCode

      void setExitCode(int exitCode)
      Sets the exit code reported by the Maven invocation.
      Parameters:
      exitCode - The exit code reported by the Maven invocation.
    • setExecutionException

      void setExecutionException(org.apache.maven.shared.utils.cli.CommandLineException executionException)
      Sets the exception that prevented to execute the command line.
      Parameters:
      executionException - The exception that prevented to execute the command line, may be null.