Sunday, November 2, 2008

Drupal Uses OOPS Concepts Or Not ?

“Drupal” - One of the most popular open sources content management system and framework built with PHP language, summary is - Drupal doesn’t use a single Class in its code base. Whole Drupal code base is based on just functions. As PHP, with which programming language Drupal itself is built, is also implementing many powerful OPP features, but Drupal is not using these features.Actually, the OOP concept is not based on uses of data structures like CLASS. It is based on the fundamentals of features like Objects, Abstraction, Encapsulation, Polymorphism, Inheritance etc.
If these fundamental features are included in programming then it can be considered in OOP.There is no keyword ‘class’ in Drupal code. Drupal is as non-OOP as many programmers do. But that is not true. Drupal doesn’t contain any class like data structure; still it is still Object Oriented.Drupal covers all these features without classes. Power of Drupal is hardly depends on this programming structure only. The way, how the hook system has been implemented in Drupal would never been possible with the use of Classes.See more details about how Drupal implements Object Oriented Programming (OOP) without using Classes, visit:http://api.drupal.org

No comments: