note 82316 deleted from language.exceptions by googleguy

From: Date: Sat, 19 Jan 2013 03:44:10 +0000
Subject: note 82316 deleted from language.exceptions by googleguy
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-193234@lists.php.net to get a copy of this message
Note Submitter: i dot crash17 at gmail dot com ---- As a response to Anonymous on 28-Dec-2007 07:25, please, remember that creating lots of MyXExtension classes is wrong if and only if your object oriented model is not well designed. One should (I even think MUST) create as many custom Exception extentions as the design needs, because every different type of exception requires (or will require, even if we haven't think about it) a different response, from showing different messages to the user, to log error messages or even kill the script. Forwarding can become confusing if you are using a big number of classes and packages, and is useless if you are using few (unless you are too lasy to write 3, 5 or 10 includes and their respective Exception classes). Remember that object orientation was created to give more semantics to the programming code so the programmer understands better what is written without having to excecute the code, so don't do things that go against that, which is the cool thing about object orientation.

« previous php.notes (#193234) next »