summaryrefslogtreecommitdiffstats
path: root/src/PHPImageWorkshop/ImageWorkshopException.php
diff options
context:
space:
mode:
Diffstat (limited to 'src/PHPImageWorkshop/ImageWorkshopException.php')
-rw-r--r--src/PHPImageWorkshop/ImageWorkshopException.php31
1 files changed, 31 insertions, 0 deletions
diff --git a/src/PHPImageWorkshop/ImageWorkshopException.php b/src/PHPImageWorkshop/ImageWorkshopException.php
new file mode 100644
index 0000000..dacce81
--- /dev/null
+++ b/src/PHPImageWorkshop/ImageWorkshopException.php
@@ -0,0 +1,31 @@
+<?php
+
+namespace PHPImageWorkshop;
+
+/**
+ * ImageWorkshopException
+ *
+ * Manage ImageWorkshop exceptions
+ */
+class ImageWorkshopException extends \Exception
+{
+ /**
+ * Constructor
+ *
+ * @param string $message
+ * @param integer $code
+ * @param Exception $previous
+ */
+ public function __construct($message, $code = 0, Exception $previous = null)
+ {
+ parent::__construct($message, $code, $previous);
+ }
+
+ /**
+ * __toString method
+ */
+ public function __toString()
+ {
+ return __CLASS__.": [{$this->code}]: {$this->message}\n";
+ }
+} \ No newline at end of file