Re: Any good advice for naming parameters of init methods?
Re: Any good advice for naming parameters of init methods?
- Subject: Re: Any good advice for naming parameters of init methods?
- From: Jens Alfke <email@hidden>
- Date: Thu, 10 Jul 2008 08:20:32 -0700
On 10 Jul '08, at 8:09 AM, an0 wrote:
I like the idea of adding prefix to my ivars, and in fact, all my C++
code use _ivars.
Good! I highly recommend that in Obj-C too. (I use "_" like you.)
However, I like the "declared properties" feature of Objective-C 2.0,
and the good feeling will be impaired if I have to explicitly bind
ivars to these declared properties like this:
@synthesize url = iUrl, title = iTitle, tags = iTags, note = iNote,
time = iTime, count = iCount.
*shrug* I don't find it much of a problem. It's just a few more
characters to type in the .m file for each property, and it has no
effect on clients of that class. As I said, I highly recommend using
ivar prefixes.
—Jens
Attachment:
smime.p7s
Description: S/MIME cryptographic signature
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden