After reading it twice, there are many points that are good, but there also some points that are not so clear cut, or plain bad. Maybe I am a bad programmer, but I disagree with some points:<p># (OOP) Writing lots of "xxxxxManager" classes that contain all of the methods for manipulating the fields of objects that have little or no methods of their own<p>I guess they keyword 'lots' make this ok, but having plain objects (scruct like), passed around in the application, and having some managers is fine. eg. if you have an application that passes around contacts, you can have a ContactsManager, taking care of all the messy bussines (local peristence, remote persitence, deleting, etc., while contacts remain simple objects. ActiveRecord pattern goes the other way, where this logic is placed in the objects. Both are fine.<p># (Relational) Treating a relational database as an object store and performing all joins and relation enforcement in client code<p>--I guess all those programmers in the "NOSql" movements are idiots. (they are not, some of these people are really smart). Don't take this statement too seriously.<p># Re-inventing or laboring without basic mechanisms that are built-into the language, such as events-and-handlers or regular expressions<p>--I think regular expressions are evil, obscure, and performance is highly depended on the implementation. Practical example, checking if an email address is valid. While some people go all the way crazy with regular expression, All I do is check that there is an '@', or a '+', at least one '.', and minimum/maximum lengths. You don't regular expressions for that, as no matter how smart you think your expression is, there is a great chance somebody that edits it will fuck it up just by changing a character on it.<p># Re-inventing classes and functions that are built-into the framework (eg: timers, collections, sorting and searching algorithms) *<p>Done many times. If you are doing mobile, most of platform implementation (at least in J2ME) just suck ass. You can't rely on them. Heck, in my previous company we did even font rendering, thread worker queues, etc. as the scheduler was unreliable, etc.<p>#Recursive subroutines that concatenate/sum to a global variable or a carry-along output variable<p>--For some problems carry-along variable are needed.<p>eg, in a binary search tree, trying to print only the nodes in a certain level.
printTreeLevel(tree, 2) -- will print only the nodes at level two<p>print(node, level)<p><pre><code> if level == 0
print node.data
else
printTreeLevel(node.left, level - 1)
printTreeLevel(node.right, level - 1)
</code></pre>
# Writing business-logic functions with tragically compromising side-effects, such as updating a user interface or performing file I/O<p>--I guess it depends on the definition of what "business-logic" is. This guy thinks it more as the transactional/model part and not a controller.
For some apps, the business logic is the main controller. Plus, "bussines logic" is more of a managerial speak anyways.<p>#Homebrew "Business Rule Engines"<p>-- Maybe I am not old enough, but I had to look it up what a "Business Rule Engine" is. Seems stuff from the Dot Com era/enterprise world.<p>#Code that tries to prevent an exploit from working by searching for the exploit's signature<p>--Haha. That's the whole Antivirus industry. I agree with him, and I don't have antivirus software, but it seems that those companies made millions by breaking this rule.