note 87695 added to language.exceptions

From: Date: Wed, 17 Dec 2008 09:33:50 +0000
Subject: note 87695 added to language.exceptions
Groups: php.notes 
Request: Send a blank email to php-notes+get-148243@lists.php.net to get a copy of this message
The internal implementation of Exception.__toString is something like this: <?php class MyException extends Exception { public function __toString() { return "exception '".__CLASS__ ."' with message '".$this->getMessage()."' in ".$this->getFile().":".$this->getLine()."\nStack trace:\n".$this->getTraceAsString(); } } ?> Useful if you want to customize your exception toString format, but not to deviate too much from the built-in one. ---- Server IP: 202.79.181.100 Probable Submitter: 202.156.12.239 ---- Manual Page -- http://www.php.net/manual/en/language.exceptions.php Edit -- https://master.php.net/note/edit/87695 Del: integrated -- https://master.php.net/note/delete/87695/integrated Del: useless -- https://master.php.net/note/delete/87695/useless Del: bad code -- https://master.php.net/note/delete/87695/bad+code Del: spam -- https://master.php.net/note/delete/87695/spam Del: non-english -- https://master.php.net/note/delete/87695/non-english Del: in docs -- https://master.php.net/note/delete/87695/in+docs Del: other reasons-- https://master.php.net/note/delete/87695 Reject -- https://master.php.net/note/reject/87695 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#148243) next »