Drupal7 coding standards

Apart from the external links below, there is far more detailed discussion of the Drupal Coding Standards here on this site - with an emphasis on compatibility with Webel's UML-friendlier PHP coding style - under the Coder module review page and under Drupal7 object-oriented coding standards.

Please get rid of the verbose Drupal "Interface" suffix naming convention !

I consider the following Drupal OO recommendation completely unnecessary and not UML-friendly:
7. Interfaces should always have the suffix "Interface".

In the The Webel «!wrapper» @Components and «!analysis» @Interfaces recipe, interfaces are instead prefixed with a capital I followed by a CamelCase name like ICamelCase. This has many advantages:

- The 'I' acts like the Interface icon in UML and makes for much easier and more compact diagramming.

- It saves a massive amount of typing !

- It makes it much easier to prompt in IDEs and UML tools like MagicDraw UML on Interface elements, by just prompting on the 'I'. How on earth is one supposed to prompt on a suffix "Interface" ?

I will fight "tooth-and-nail" to get rid of the DrupalInterface suffix convention !

It has clearly been conceived by people who are likely not frequent graphical UML users, and are perhaps even relatively new to object-orientation. In modern IDE's like NetBeans or Eclipse and when using graphical UML support it is already perfectly clear whether something is an interface or not, one does not need to spell it out painfully with the word Interface. The UML-friendly OOE = Object Oriented Examples = One Of Each module will never, under any circumstances, adopt the verbose "Interface" suffix convention.

If you are likewise opposed to this convention, please join the debate at: Drupal.org: Object-oriented code (naming conventions): Please relax the verbose Drupal "Interface" suffix convention !

Visit also

Visit also