messageToLog = $message; parent::__construct('', $code, $previous); } public function __toString() { return sprintf( "%s %s in %s(%s)\n\t\t\t%s", get_class($this), $this->messageToLog, $this->file, $this->line, $this->getTraceAsString() ); } }