• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Seeking comments: an Objective-C reference card for Java programmers
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Seeking comments: an Objective-C reference card for Java programmers


  • Subject: Re: Seeking comments: an Objective-C reference card for Java programmers
  • From: Ken Ferry <email@hidden>
  • Date: Tue, 30 Nov 2004 15:58:23 -0500

On Sat, 27 Nov 2004 15:51:47 -0800, Dylan McNamee <email@hidden> wrote:
>
> If anyone finds it useful, that's great.
>
> I'd also appreciate any feedback / errata / suggestions for improvement.
> I do want to keep it to one side of one page, though.
>
> Here's the file:  http://www.mecodegoodsomeday.com/ObjectiveCRef.pdf

Looks very useful!

You could clarify the use of autorelease.  Maybe show that the
principal use is to return an object without transferring ownership to
the calling function.

The current text,
"autorelease performs a release at some point in the future after the
current stack frame is exited"

doesn't make it clear that the object will survive being returned.

Of course it's hard to compose clear, concise text.  How about,
"Only methods that start with init, new, copy or retain return objects
that have to be released by the caller.  To return an object that
doesn't need releasing, it's often useful to send the object the
autorelease message.  Autorelease works like a deferred release."

-Ken
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >Seeking comments: an Objective-C reference card for Java programmers (From: Dylan McNamee <email@hidden>)

  • Prev by Date: Re: LSUIElement does not work as documented?
  • Next by Date: Re: iSight/Address Book Image Selection UI
  • Previous by thread: Re: Seeking comments: an Objective-C reference card for Java programmers
  • Next by thread: How do I get around this?
  • Index(es):
    • Date
    • Thread