Re: Re: [PEPr] +1 for File System::System_WinDrives

From: Date: Wed, 08 Dec 2004 12:05:42 +0000
Subject: Re: Re: [PEPr] +1 for File System::System_WinDrives
References: 1  Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-34907@lists.php.net to get a copy of this message
Just as comment on the loop. You could also use: foreach (range('C', 'Z') as $drive) { // do something } which looks a tad less hackish as the example you give below. As for the Hungarian notation, as long as the vars are indeed private and should be only accessed via the class methods, I do not see the harm. It is just that that particular notation is kind of strange for a lossely typed language and redundant if the code is well documented. Cheers. --- Christian Weiske <cweiske@cweiske.de> wrote: > > - don't use hungarian notation > > - there's no need to use ord() and chr() in your for loops > > - would be nice if one could "mount" network shares, or eject CDR trays > > Michael and I came to the following results: > - I can loop through all drives from a until z with > for ($d = 'C'; $d <= 'Z'; $d++) > - (um)mounting network shares would be a great enhancement > - hungarian notation is not prohibited in the pear doc manual; it's just > that there aren't many people which use it > > > Regards/MfG, > Christian Weiske > -- > XMMS is playing now: > > > ATTACHMENT part 2 application/pgp-signature name=signature.asc ===== -- Jesus M. Castagnetto (jcastagnetto@yahoo.com) Web site: http://www.castagnetto.org/ Research: http://metallo.scripps.edu/ PEAR stuff: http://pear.php.net/user/jmcastagnetto __________________________________ Do you Yahoo!? Yahoo! Mail - Helps protect you from nasty viruses. http://promotions.yahoo.com/new_mail

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