If this is going to be done it probably needs to be done in 3.1 otherwise we will be breaking BC.
Conventions
We should be following PSR-0
There would need to be coding guidelines added with regards to this and the use of use statements https://github.com/php-fig/fig-standard ... clarations and https://github.com/php-fig/fig-standard ... lass-names
Vendor name should be phpBB (That is what we have been using in other sub-projects already for a while).
Must be fully qualified as:
\phpBB\<directories\from\includes>\<Class Name>
Underscores are treated as directory seperators so directory structures must be updated accordingly.
Example:
phpbb_extension_metadata_manager
must now be located in phpBB/includes/extension/metadata/manager.php
would have the namespace \phpBB\extension\metadata_manager
or \phpBB\extension\metadata\manager
. This looks very weird due to our currently casing rules. As such as part of this RFC I propose that all new classes should be StudlyCaps in which case it would become \phpBB\Extension\MetadataManager
and methods become camelCase.Autoloading
We could probably use a library for our autoloader as well instead of updating our current one. The two options I see we have are using composer's autoloading and symfony autoloader. Both use FIG's PSR-0 standard.
There isn't much difference between them, composer was based upon symfony's universal class loader. http://stackoverflow.com/questions/1389 ... autoloader
Symfony Autoloader: https://github.com/symfony/ClassLoader & http://symfony.com/doc/current/componen ... oader.html
Composer Autoloader: https://github.com/composer/composer/tr ... r/Autoload