With sincere gratitude from Webel IT Australia to Drupal CMS. Although it's not perfect, it is very powerful and is very popular with good reason.
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.
- External: Configuring NetBeans (to format your code according to Drupal Coding Standards).
Please get rid of the verbose Drupal "Interface" suffix naming convention !
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" ?
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 !
Backlinks:
This educational site is brought to you by Webel IT Australia, experts in database-driven web technology for industry, engineering, education and science. Webel is one of Australia's most experienced Drupal CMS web site specialists.
'It ain't necessarily so,
It ain't necessarily so,
The t'ings dat yo' li'ble,
To read in de [Drupal6/7] Bible,
It ain't necessarily so.'
Heresy: Doctrine rejected as false by religious authorities.
Logical fallacy: Appeal to popularity, Argumentum ad populum.
© Copyright 2001 - 2016 Webel IT Australia (ABN: 67 677 268 579). All rights reserved (except as specified below).
PHP code examples from Webel IT Australia on this site are distributed under the GNU General Public License.
Excludes text and code snippets from Drupal.org quoted for educational purposes.
Drupal’s online documentation is © 2000-2014 by the individual contributors and can be used in accordance with the Creative Commons License, Attribution-ShareAlike 2.0.
PHP code from Drupal.org is distributed under the GNU General Public License.
Drupal® is a registered trademark of Dries Buytaert.
Text quoted from Wikipedia for educational purposes is made available under the Creative Commons Attribution-ShareAlike License.
Wikipedia® is a registered trademark of the Wikimedia Foundation, Inc., a non-profit organization.
Site developed by Webel IT Australia.