Security update for permissions_by_term
[yaffs-website] / vendor / behat / behat / src / Behat / Testwork / Call / Handler / ExceptionHandler.php
diff --git a/vendor/behat/behat/src/Behat/Testwork/Call/Handler/ExceptionHandler.php b/vendor/behat/behat/src/Behat/Testwork/Call/Handler/ExceptionHandler.php
new file mode 100644 (file)
index 0000000..53a35f7
--- /dev/null
@@ -0,0 +1,39 @@
+<?php
+
+/*
+ * This file is part of the Behat Testwork.
+ * (c) Konstantin Kudryashov <ever.zet@gmail.com>
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Behat\Testwork\Call\Handler;
+
+/**
+ * Handles exceptions.
+ *
+ * @see CallCenter
+ *
+ * @author Konstantin Kudryashov <ever.zet@gmail.com>
+ */
+interface ExceptionHandler
+{
+    /**
+     * Checks if handler supports exception.
+     *
+     * @param \Throwable $exception
+     *
+     * @return bool
+     */
+    public function supportsException($exception);
+
+    /**
+     * Handles exception and returns new one if necessary.
+     *
+     * @param \Throwable $exception
+     *
+     * @return \Throwable
+     */
+    public function handleException($exception);
+}