Re: PEAR Coding Standards

From: Date: Fri, 13 Dec 2002 22:20:14 +0000
Subject: Re: PEAR Coding Standards
References: 1  Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-11640@lists.php.net to get a copy of this message
<bmansion@mamasam.com> wrote : > <pear-dev@meebey.net> wrote : > >> >> At the moment the code is only avialable here: >> http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/phpsmartirc >> >> the thing is the constants will look very ugly... >> And I use alot of them, since PHP has no ENUM's >> >>> >>> Hmm, what is the problem? a simple search and replace in vi/vim/emacs can do >>> it >>> fast. I do not see Net_SmartIRC on CVS so I cannot tell how difficult it'll >>> be, >>> but usually is almost trivial. >>> >>> Where is your code again? > > Hi Mirco, > > You have to use special rules for your constants. Why ? Because some people > might use the same constants in their own code in which case there will be a > conflict between your class and their code. For example, all constants for > HTML_QuickForm start with HTML_QUICKFORM_... In your case, it will be > NET_SMARTIRC_... or NET_IRC_... if as suggested by Stig, you choose to > update the current Net_IRC class for a version 2 (which I think would be a > good idea). Damn, I should have read all threads before posting :-) And sorry about the double CC... :-D Bertrand Mansion Mamasam

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