const RESULT_INDEX_STATUS = 'status';
const RESULT_INDEX_EXCEPTION = 'exception';
+ /**
+ * Last thrown exception or NULL if all is fine
+ */
+ private $lastException = NULL;
+
/**
* Protected constructor
*
// Call parent constructor
parent::__construct($className);
}
+
+ /**
+ * Getter for last exception
+ *
+ * @return $lastException Last thrown exception
+ */
+ public final function getLastException () {
+ return $this->lastException;
+ }
+
+ /**
+ * Setter for last exception
+ *
+ * @param $lastException Last thrown exception
+ * @return void
+ */
+ public final function setLastException (FrameworkException $exceptionInstance) {
+ $this->lastException = $exceptionInstance;
+ }
+
+ /**
+ * Reset the last exception instance. This should be done after a "query"
+ * was completed without any errors.
+ *
+ * @return void
+ */
+ protected final function resetLastException () {
+ $this->lastException = NULL;
+ }
}
// [EOF]