On 08/11/06, Mike Keesey <[EMAIL PROTECTED]> wrote:
> That's just bad coding. Don't use class variable names as argument
> names. It's not like you don't have a choice about it. ;)
I don't think it's "bad" coding. Documentation generated from this
signature might be a bit clearer than documentation generated from a
signature where the argument was, e.g., "nameValue", since it would be
more immediately obvious that the argument "name" corresponds to the
property "name". That said, the code itself is clearer the other way.
Six of one and half a dozen of the other. (Programming is so often like
that.)
--
Mike Keesey
I prefer the the double underscore naming scheme to differentiate a
local/arugment variable from a class variable. It helps when you want to
create get/set functions and reminds you that it is a private variable and
should not accessed directly.
class Student
{
private var __name:String;
public function Student(name:String)
{
__name = name;
}
}
--
Go Dennis!
_______________________________________________
[email protected]
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com