I'm resistant to calling the "main" class the same as the namespace, but I sometimes find myself needing it. Considering I'm using the Vendor.Namespace.[Subnamespace].Class
formula, imagine this scenario:
[MyFramework]
[Database]
Database
Sql
Schema
DriverAbstract
DriverInterface
[Drivers]
Mysql
Postgresql
Sqlite
obs: []
are for namespaces, the others are classes.
Now, I could call the Database
class Connection
instead, but when I import the namespace MyFramework.Database
I would only see Connection
in the code (but connection to what?). Other solution would be calling it DatabaseConnection
, but is that really necessary? I would like to hear your thoughts and ideas on that problem. Thank you (:
Sidequest: also, what are your thougths on DriverAbstract
and DriverInterface
? Should they fit better in the [Drivers]
namespace? Should I call DriverAbstract
just Driver
?