Reputation: 2375
In the system, we have settings for users and the system itself. Typically, I might name their controllers and other objects something like SystemSettingsController
and UserSettingsController
. I'm separating the controllers though into their own folders and so they have different namespaces.
Has anyone considered the object's namespace in naming the object and is that proper usage of it? I'm thinking of doing something like users\SettingsController
and system\SettingsController
instead. So they have the same name, but the differences can be distinguished by their namespaces.
Upvotes: 2
Views: 61
Reputation: 107
You can write:
use Carrington/User/SettingsController as UserSettingsController;
use Carrington/System/SettingsController as SystemSettingsController;
To separate the classes from each other
Upvotes: 2