aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/ftbsc/lll/exceptions
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/ftbsc/lll/exceptions')
-rw-r--r--src/main/java/ftbsc/lll/exceptions/AmbiguousDefinitionException.java12
-rw-r--r--src/main/java/ftbsc/lll/exceptions/InvalidClassNameException.java15
-rw-r--r--src/main/java/ftbsc/lll/exceptions/InvalidResourceException.java22
3 files changed, 16 insertions, 33 deletions
diff --git a/src/main/java/ftbsc/lll/exceptions/AmbiguousDefinitionException.java b/src/main/java/ftbsc/lll/exceptions/AmbiguousDefinitionException.java
index 1befaa8..a00c2e2 100644
--- a/src/main/java/ftbsc/lll/exceptions/AmbiguousDefinitionException.java
+++ b/src/main/java/ftbsc/lll/exceptions/AmbiguousDefinitionException.java
@@ -1,8 +1,7 @@
package ftbsc.lll.exceptions;
/**
- * Thrown when the processor finds multiple methods matching the
- * given criteria.
+ * Thrown when the processor finds multiple methods matching the given criteria.
*/
public class AmbiguousDefinitionException extends RuntimeException {
@@ -13,13 +12,4 @@ public class AmbiguousDefinitionException extends RuntimeException {
public AmbiguousDefinitionException(String message) {
super(message);
}
-
- /**
- * Constructs a new ambiguous definition exception with the specified detail message and cause.
- * @param message the detail message
- * @param cause the cause, may be null (indicating nonexistent or unknown cause)
- */
- public AmbiguousDefinitionException(String message, Throwable cause) {
- super(message, cause);
- }
}
diff --git a/src/main/java/ftbsc/lll/exceptions/InvalidClassNameException.java b/src/main/java/ftbsc/lll/exceptions/InvalidClassNameException.java
new file mode 100644
index 0000000..caa468e
--- /dev/null
+++ b/src/main/java/ftbsc/lll/exceptions/InvalidClassNameException.java
@@ -0,0 +1,15 @@
+package ftbsc.lll.exceptions;
+
+/**
+ * Thrown when the user provides manually an invalid class name.
+ */
+public class InvalidClassNameException extends RuntimeException {
+
+ /**
+ * Constructs a new exception for the specified name.
+ * @param name the name in question
+ */
+ public InvalidClassNameException(String name) {
+ super(String.format("Provided class name %s is not valid!", name));
+ }
+}
diff --git a/src/main/java/ftbsc/lll/exceptions/InvalidResourceException.java b/src/main/java/ftbsc/lll/exceptions/InvalidResourceException.java
deleted file mode 100644
index 76f12a5..0000000
--- a/src/main/java/ftbsc/lll/exceptions/InvalidResourceException.java
+++ /dev/null
@@ -1,22 +0,0 @@
-package ftbsc.lll.exceptions;
-
-/**
- * Thrown when a resource passed as an argument is not found.
- */
-public class InvalidResourceException extends RuntimeException {
-
- /**
- * Empty constructor, used when the provided resource exists but is empty.
- */
- public InvalidResourceException() {
- super("The specified resource was empty!");
- }
-
- /**
- * Named constructor, used when the specified resource doesn't exist.
- * @param name the resource name
- */
- public InvalidResourceException(String name) {
- super(String.format("Specified resource %s was not found!", name));
- }
-}