PEAR Coding Standards question

From: Date: Tue, 19 Aug 2008 16:39:16 +0000
Subject: PEAR Coding Standards question
Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-50561@lists.php.net to get a copy of this message
Hello, I have a question about the PEAR CS. Why are the coding conventions so that I'm not allowed to prefix protected methods with an underscore? e.g. I like my: 'protected function _rerouteTraffic' instead of: 'protected function rerouteTraffic' (which to me - when future referencing - makes it look like a method that can be called from outside) I would have opted for 'private function_rerouteTraffic' methods, just to make that visual distinction. But private methods give me inheritance issues when extending classes. I extend a lot. So now in most of my projects, this leaves me with mainly public & protected class methods. And no visual differentiation between them, unless I: - come up with my own unconventional and ugly prefixes: 'priMethod', 'proMethod', 'pubMethod' :( noooh... - break PEAR CS conventions :'( nooooohhoooo..... Which frankly, I both don't really like (as emphasized by the smilies) To me it would make more sense to prefix both protected & private functions with an underscore. Could anyone either: - talk some sense into me - loosen/change the phpcs Or should I just |grep -v and be on my way. -- Met vriendelijke groet / Kind regards, Kevin van Zonneveld http://pear.php.net/package/System_Daemon

« previous php.pear.dev (#50561) next »