Welcome Guest, Not a member yet? Register   Sign In
CI and namespaces
#11

[eluser]Michael Wales[/eluser]
Well, we both know it will be awhile before we see any of this enter CI - PHP4 has a long ways to go before it dies.

To be honest, I'm not as familiar with PHP5's namespace implementation as I should be - I guess I ought to do some reading up on it but my first guess is that it would be difficult to support both PHP4 and PHP5 (via the base file that CI loads, dependent upon versioning).

Your comment about multiple applications is valid and one I didn't even think of (although I am currently running 7 apps off the same framework installation).

My primary concern with namespacing is the length that they can become at times. It really irks me when the solution to such a simple problem (collisions) is 60 characters long... there has to be a simpler way. Not saying namespacing is a bad idea - but it can be implemented very poorly.

My first thoughts - purely aesthetic with no thinking in regards to actual functionality and ease of implementation, nothing more than prettiness:

Code:
EllisLab::CI::Validation
EllisLab::CI::Controller
EllisLab::CI::Database
// Extended Library
MichaelWales::CI::Validation
// Controller
MichaelWales::HireMeAnchorage::Job
// Model
MichaelWales::HireMeAnchorage::Jobs
#12

[eluser]porquero[/eluser]
I'm found a solution to work with namespaces.
see http://ellislab.com/forums/viewthread/212661/




Theme © iAndrew 2016 - Forum software by © MyBB