Re: Style Question
Re: Style Question
- Subject: Re: Style Question
- From: "Alex Wait" <email@hidden>
- Date: Fri, 27 Jun 2008 22:15:57 -0700
I was meaning to imply that if it was called "FirstName" would setFirstName
still be called?
I know the convention for naming variables. :)
On Fri, Jun 27, 2008 at 10:13 PM, Jens Alfke <email@hidden> wrote:
>
> On 27 Jun '08, at 9:44 PM, Alex Wait wrote:
>
> if I have a member, let's say a NSString, called FirstName...
>> would the setter still be setFirstName?
>>
>
> Yes. But you shouldn't name the property "FirstName". Property and method
> (and instance variable) names should be lowercased. There are some
> exceptions made when the name begins with an acronym, most commonly "URL",
> that needs to remain uppercase for legibility.
>
> Honestly, no one reading your code is going to care whether you put braces
> at the end of a line or on a new line. But naming conventions are important
> and can help or confuse other people (or yourself, a year later) trying to
> understand it.
>
> —Jens
--
If you can't be kind, at least have the decency to be vague.
_______________________________________________
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