Re: When to use exception, or When not to use exception

From: Date: Fri, 23 Feb 2007 16:11:02 +0000
Subject: Re: When to use exception, or When not to use exception
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-249296@lists.php.net to get a copy of this message
Hello, You can use the following tutorial for error handling in PHP :) http://www.devshed.com/c/a/PHP/Error-Handling-in-PHP-Introducing-Exceptions-in-PHP-5/ -- Haydar TUNA Republic Of Turkey - Ministry of National Education Education Technology Department Ankara / TURKEY Web: http://www.haydartuna.net ""js "" <ebgssth@gmail.com>, haber iletisinde sunlari yazdi:a23effaf0702210828t6c14999ew639ec03f1cbadde5@mail.gmail.com... > Hello list, > > Recently I upgraded my dev environment and started to use PHP5 at last! > Compared with the former one, PHP5 rocks in many ways. > So I love it so much, but sadly, I don't exactly know when to use > exception. > I'm never used to use Java, or languages that support exceptin > so I have to learn the usage.. > > So, my question is > When to use, or when not to use exception? > Now I'm using exception in 99% to handle errors because it's easier and > cleaner. > The only problem I have using exception instead of normal > "if-error-then" method is > that I have to define logs of Exception-derived classes to effectively > handling erros. > It's cumbersome but not so bad compared with traditional error handling. > > > Any suggestions, personal guidelines, tutoriral, documentation would > be greatly appriciated.

« previous php.general (#249296) next »