Exceptional PHP: Nesting Exceptions In PHP

Thursday, November 12th, 2009

In the last two entries we have talked about the concept of layer abstraction: that is, that exceptions should not be allowed to pass out of one layer and into another. So, when an exception is raised in the database layer it should be caught in the controller. But how do we go about making [...]

1:00 am | Comment (1) | Print | Categories: Best Practices, Object-Oriented Development, PHP 5

Exceptional PHP: Extending The Base Exception Class

Wednesday, November 11th, 2009

On Monday, we talked about the basics of exceptions and how they are used in PHP (as well as in other object-oriented programming languages). As promised, today we are going to talk about extending the base exception class in PHP.

1:00 am | Comment (5) | Print | Categories: Best Practices, Object-Oriented Development, PHP 5

Exceptional PHP: Introduction to Exceptions

Monday, November 9th, 2009

A great feature of PHP is the ability to throw and catch exceptions. This feature was introduced in PHP 5, and has been around for years in other languages like Python.

1:00 am | Comment (9) | Print | Categories: Best Practices, Object-Oriented Development, PHP 5

Five Tips To Make Good Object-Oriented Code Better

Wednesday, October 28th, 2009

Last week, I did a talk at the Frederick Web meetup about tips and tricks for improving your object-oriented code. A lot of these tips were adapted from a fabulous presentation by Stefan Priebsch but the ideas are by no means original to him, and they’re exceptionally good ideas when you’re talking about object-oriented code. [...]

1:00 am | Comment (13) | Print | Categories: Best Practices, PHP 5, System Architecture

What Interfaces Are For

Wednesday, October 7th, 2009

A little while ago, I wrote an article discussing why interfaces rock and the way that interfaces work. However, a couple of comments made me realize that I didn’t discuss one of the key elements about interfaces: why you would use them.

1:00 am | Comment (6) | Print | Categories: PHP 5
« Older Entries
Newer Entries »
Search:
Copyright © 2008 - 2010. All Rights Reserved.