You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by mi...@apache.org on 2021/09/24 19:16:37 UTC
[maven] branch master updated: [MNG-7164] Add constructor
MojoExecutionException(Throwable)
This is an automated email from the ASF dual-hosted git repository.
michaelo pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/maven.git
The following commit(s) were added to refs/heads/master by this push:
new ad2e084 [MNG-7164] Add constructor MojoExecutionException(Throwable)
ad2e084 is described below
commit ad2e084ba8e6d20f6da93d06363d82f1e31d4137
Author: Gary Gregory <gg...@rocketsoftware.com>
AuthorDate: Sat May 29 09:31:49 2021 -0400
[MNG-7164] Add constructor MojoExecutionException(Throwable)
This closes #474
---
.../apache/maven/plugin/AbstractMojoExecutionException.java | 12 ++++++++++++
.../org/apache/maven/plugin/MojoExecutionException.java | 13 +++++++++++++
.../java/org/apache/maven/plugin/MojoFailureException.java | 13 +++++++++++++
3 files changed, 38 insertions(+)
diff --git a/maven-plugin-api/src/main/java/org/apache/maven/plugin/AbstractMojoExecutionException.java b/maven-plugin-api/src/main/java/org/apache/maven/plugin/AbstractMojoExecutionException.java
index 52aded3..e8df309 100644
--- a/maven-plugin-api/src/main/java/org/apache/maven/plugin/AbstractMojoExecutionException.java
+++ b/maven-plugin-api/src/main/java/org/apache/maven/plugin/AbstractMojoExecutionException.java
@@ -41,6 +41,18 @@ public abstract class AbstractMojoExecutionException
super( message, cause );
}
+ /**
+ * Constructs a new {@code AbstractMojoExecutionException} exception wrapping an underlying {@code Throwable}.
+ *
+ * @param cause the cause which is saved for later retrieval by the {@link #getCause()} method.
+ * A {@code null} value is permitted, and indicates that the cause is nonexistent or unknown.
+ * @since 3.8.3
+ */
+ public AbstractMojoExecutionException( Throwable cause )
+ {
+ super( cause );
+ }
+
public String getLongMessage()
{
return longMessage;
diff --git a/maven-plugin-api/src/main/java/org/apache/maven/plugin/MojoExecutionException.java b/maven-plugin-api/src/main/java/org/apache/maven/plugin/MojoExecutionException.java
index 4d8c416..6d08989 100644
--- a/maven-plugin-api/src/main/java/org/apache/maven/plugin/MojoExecutionException.java
+++ b/maven-plugin-api/src/main/java/org/apache/maven/plugin/MojoExecutionException.java
@@ -76,4 +76,17 @@ public class MojoExecutionException
{
super( message );
}
+
+ /**
+ * Constructs a new {@code MojoExecutionException} exception wrapping an underlying {@code Throwable}.
+ *
+ * @param cause the cause which is saved for later retrieval by the {@link #getCause()} method.
+ * A {@code null} value is permitted, and indicates that the cause is nonexistent or unknown.
+ * @since 3.8.3
+ */
+ public MojoExecutionException( Throwable cause )
+ {
+ super( cause );
+ }
+
}
diff --git a/maven-plugin-api/src/main/java/org/apache/maven/plugin/MojoFailureException.java b/maven-plugin-api/src/main/java/org/apache/maven/plugin/MojoFailureException.java
index 342d081..72faec6 100644
--- a/maven-plugin-api/src/main/java/org/apache/maven/plugin/MojoFailureException.java
+++ b/maven-plugin-api/src/main/java/org/apache/maven/plugin/MojoFailureException.java
@@ -65,4 +65,17 @@ public class MojoFailureException
{
super( message, cause );
}
+
+ /**
+ * Constructs a new {@code MojoFailureException} exception wrapping an underlying {@code Throwable}.
+ *
+ * @param cause the cause which is saved for later retrieval by the {@link #getCause()} method.
+ * A {@code null} value is permitted, and indicates that the cause is nonexistent or unknown.
+ * @since 3.8.3
+ */
+ public MojoFailureException( Throwable cause )
+ {
+ super( cause );
+ }
+
}