 | News Feed |
Sections
Community Events
Don't see your event here? Let us know!
|
| feed this: |  |
Zend Developer Zone: Book Review Object-Oriented Programming with PHP5
posted Tuesday June 24, 2008 @ 11:14:28
voice your opinion now!
BY CHRIS CORNUTT
The Zend Developer Zone has published a new book review covering the Packt Publishing book from Hasin Hayder, "Object-Oriented Programming with PHP5".
The book does a decent job of covering the main OOP topics in PHP; as well as, touching upon some of the peripheral ones. Hayder devotes whole chapters to such topics as unit testing, design patterns, XML, SPL, and working with databases.
The review talks about the "Good", the "Bad" and the "Ugly" of the book ranging from the good code examples and the chapter on the SPL down to the flawed version of the Singleton used and the lack of commentary/explanations around the code.
tagged with: php5 book review object oriented programming
DevShed: Utilizing Private Methods with PHP 5 and Member Visibility
posted Thursday June 19, 2008 @ 07:58:51
voice your opinion now!
BY CHRIS CORNUTT
DevShed has posted the fifth part of their series looking at the visibility keywords on PHP5's object oriented support today. They've already looked at private, public and protected properties in a class, now they look at the use of making methods private to restrict their use/extension.
Of course, when it comes to specifying how visible a certain class property or method will be, you know that PHP 5 permits you to work with three distinct levels of access, called "public," "protected," and "private" respectively. [...] As you may have noticed, however, I've not taught you how to define private methods yet, which is something that can definitely be very useful if you want to restrict the access to your classes from the outside more severely.
The tutorial shows the creation of a class with private properties and then expands it to include a private method. Then they call it from an object, an example of the error PHP kicks back is there too. He also includes the concept of a "getter" to call the private function from a public one.
tagged with: private object oriented php5 method tutorial getter
Alex Netkachov's Blog: Are setters evil?
posted Tuesday June 17, 2008 @ 09:36:03
voice your opinion now!
BY CHRIS CORNUTT
Alex Netkachov has posted his own response to this opinion on the Typical Programmer on getters and setters in object-oriented applications.
"Do not use getters and setters" looks like a hastily advise, but its meaning is very important and it is "do not break encapsulation", which moves us to the question what the encapsulation is.
He notes that encapsulation is, in essence, hiding parts of the code away so that the user/other coders only see a little bit of the magic that happens. He argues that getters and setters are a valid part of the encapsulation process and that designing a good, easy to use system almost requires them.
tagged with: setter getter object oriented programming encapsulation
Typical Programmer Blog: Doing it wrong getters and setters
posted Monday June 16, 2008 @ 11:19:17
voice your opinion now!
BY CHRIS CORNUTT
According to this new post on the Typical Programmer blog, using getters and setters in your scripts only adds in a bit of unnecessary coupling and complexity to your scripts that you just don't need.
Today most of the popular programming languages support objects, limiting scope, modularity, passing by value, and sophisticated built-in types. There should be no reason to deliberately expose an object's data to the rest of the code because the language can enforce encapsulation and data hiding.
While not specific to PHP, the post does recommend against them because of one simple reason common to all languages that make them possible - they "break the encapsulation OOP offers". For them, they're like a cheat to get around bad coding practices and are not needed to make a successful application work.
tagged with: getter setter break object oriented encapsulation scope bad
Kae Verens' Blog: review Object-Oriented Programming in PHP5
posted Thursday May 29, 2008 @ 07:53:43
voice your opinion now!
BY CHRIS CORNUTT
Kae Verens has posted a review of a PHP-related book from APress Publishing, "Object-Oriented Programming in PHP5":
In short: a very good concise introduction to OOP. I'll be keeping this on my desk for a while. The language use is strange but the code examples and the spread of topics make up for that in spades. This book has a very broad scope, but is clear in the essentials. If you're looking for an introduction to Objected Oriented Programming in PHP, I'd recommend this one.
The review gets into a bit more detail on "The Good", "The Bad" and "The Ugly" of its contents including its intro to OOP in PHP (good), the assumption that OOP is better than other programming types (bad) and the poor structure of the book (the ugly).
tagged with: book review apress object oriented programming php5
Zend Developer Zone: Mobile Platforms Built On Object-Oriented PHP 5
posted Wednesday May 28, 2008 @ 07:53:43
voice your opinion now!
BY CHRIS CORNUTT
A new post on the Zend Developer Zone points out a talk that's going to be given at the National Arts Club about making mobile platforms with the help of PHP5.
Kargo derives significant competitive advantage as their application designers & producers make use of Zend Framework to build their next generation mobile application platform on. [...] Zend Technologies will present an introduction to the modular "use at will" PHP 5 components in Zend Framework and Kargo will outline the high-performance messaging server and mobile internet platform they've built.
You can find out more about the meetup from its page on Upcoming and check out this page for more details and a map to the location (New York, NY).
tagged with: php5 kargo zendframework mobile platform object oriented
|