diff options
Diffstat (limited to 'src/main/java/org/bukkit/plugin/InvalidPluginException.java')
-rw-r--r-- | src/main/java/org/bukkit/plugin/InvalidPluginException.java | 25 |
1 files changed, 22 insertions, 3 deletions
diff --git a/src/main/java/org/bukkit/plugin/InvalidPluginException.java b/src/main/java/org/bukkit/plugin/InvalidPluginException.java index 66abea74..ba1fc07e 100644 --- a/src/main/java/org/bukkit/plugin/InvalidPluginException.java +++ b/src/main/java/org/bukkit/plugin/InvalidPluginException.java @@ -4,7 +4,7 @@ package org.bukkit.plugin; * Thrown when attempting to load an invalid Plugin file */ public class InvalidPluginException extends Exception { - private static final long serialVersionUID = -8242141640709409543L; + private static final long serialVersionUID = -8242141640709409544L; /** * Constructs a new InvalidPluginException based on the given Exception @@ -12,13 +12,32 @@ public class InvalidPluginException extends Exception { * @param cause Exception that triggered this Exception */ public InvalidPluginException(final Throwable cause) { - super("Invalid plugin" + (cause != null ? ": " + cause.getMessage() : ""), cause); + super(cause); } /** * Constructs a new InvalidPluginException */ public InvalidPluginException() { - this(null); + + } + + /** + * Constructs a new InvalidPluginException with the specified detail message and cause. + * + * @param message the detail message (which is saved for later retrieval by the getMessage() method). + * @param cause the cause (which is saved for later retrieval by the getCause() method). (A null value is permitted, and indicates that the cause is nonexistent or unknown.) + */ + public InvalidPluginException(final String message, final Throwable cause) { + super(message, cause); + } + + /** + * Constructs a new InvalidPluginException with the specified detail message + * + * @param the detail message. The detail message is saved for later retrieval by the getMessage() method. + */ + public InvalidPluginException(final String message) { + super(message); } } |