summaryrefslogtreecommitdiff
path: root/src/main/java/ftbsc/geb/exceptions/MissingInterfaceException.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/ftbsc/geb/exceptions/MissingInterfaceException.java')
-rw-r--r--src/main/java/ftbsc/geb/exceptions/MissingInterfaceException.java17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/main/java/ftbsc/geb/exceptions/MissingInterfaceException.java b/src/main/java/ftbsc/geb/exceptions/MissingInterfaceException.java
new file mode 100644
index 0000000..e792729
--- /dev/null
+++ b/src/main/java/ftbsc/geb/exceptions/MissingInterfaceException.java
@@ -0,0 +1,17 @@
+package ftbsc.geb.exceptions;
+
+/**
+ * Thrown when a parent of a listener method does not implement the
+ * appropriate interface,
+ */
+public class MissingInterfaceException extends RuntimeException {
+
+ /**
+ * The public constructor.
+ * @param clazz the fully-qualified name of the parent class
+ * @param method the annotated listener method
+ */
+ public MissingInterfaceException(String clazz, String method) {
+ super(String.format("The parent of %s::%s does not implement the IListener interface!", clazz, method));
+ }
+}