[Owncloud] namespacing

Frank Karlitschek frank at owncloud.org
Sun Apr 22 12:28:33 UTC 2012


Hi everybody,

currently all Classes in ownCloud start with OC_
This leads to a problem if one app wants to use a class name thats already used in the core or in another app.
A second problem is that we want to build a public api that's stable across different ownCloud version. If apps calls all the internal classes/functions or session variable we run into a problem in the long run.

Because of that I propose this new namespacing schema:

OC_  "ownCloud " Reserver for internal classes and session variables or the core
OCP_ "ownCloud public" Reserved for the new public API that has to be used by apps exclusively. (Still has to be build)
OCA_"appidentifier"_  "ownCloud App" Reserver for use in ownCloud apps. The unique identifier has to be in the class name so that it doesn`t clash with other apps.


What do you think?


Cheers
Frank


More information about the Owncloud mailing list