But in a way, using the namespace like suggested is much more PHP-ish. After all, your class does not have sensible instances. There is not much OOP about it.
Where there is something not-much-OOP about something, PHP supplies global functions (compare md5() to 5 lines of Java code) instead of classes. So, using global functions would. in many ways, be much more PHP-ish than using static class methods (which is more Java-ish if you ask me).
Of course, you don't want to pollute the global namespace too much, so using the '_' namespace sounds excellent. I really like the idea.
Comments
But in a way, using the namespace like suggested is much more PHP-ish. After all, your class does not have sensible instances. There is not much OOP about it.
Where there is something not-much-OOP about something, PHP supplies global functions (compare md5() to 5 lines of Java code) instead of classes. So, using global functions would. in many ways, be much more PHP-ish than using static class methods (which is more Java-ish if you ask me).
Of course, you don't want to pollute the global namespace too much, so using the '_' namespace sounds excellent. I really like the idea.
Namespaces might be more PHP-ish, but I was primarily concerned with being Underscore-ish.
I'm also not entirely opposed to the namespace approach, but syntactically I would rather call:
than