Re: Seeking comments: an Objective-C reference card for Java programmers
Re: Seeking comments: an Objective-C reference card for Java programmers
- Subject: Re: Seeking comments: an Objective-C reference card for Java programmers
- From: "M. Uli Kusterer" <email@hidden>
- Date: Sun, 28 Nov 2004 05:09:49 +0100
At 15:51 Uhr -0800 27.11.2004, Dylan McNamee wrote:
I'm a "big fan" of Cocoa-Java, but I thought I'd explore the other side
of things in my next project, and delve into Objective-C. I'm finding
myself reaching for the same little syntax templates, so I wrote a
reference card to save some time.
If anyone finds it useful, that's great.
Whoa, wish I'd had that when I started out! Well, I'm handing it on
to my sister, who is just working on her first Cocoa app, and making
progress by leaps and bounds... Thanks a lot!
I'd also appreciate any feedback / errata / suggestions for improvement.
I do want to keep it to one side of one page, though.
Well, it's great, so I don't really have to offer any important
corrections, but there are four tweaks I could see:
1) It may be handy to mention that @synchronized and @try/@throw are
10.3 and later only. For @try/@throw the old technique was
NS_DURING/[NSException raise]
2) The description of dealloc is kind of misleading. Since reference
card are ideal for beginners, it'd probably be helpful if it
explicitly said that of course only objects retained in instance
variables need to be released in dealloc, not literally *every*
object you just allocate in init.
3) Do we want to mention that you don't actually *have to* implement
an informal protocol? Declaring its interface is enough to make the
names known, which lets you check using respondsToSelector: whether
it's actually implemented.
4) Do we want to also offer an example for calls directly on a string
constant? ([@"String" uppercaseString]; or so) Or is that an
absolutely obvious technique that only took me a while to realize was
of course valid?
--
Cheers,
M. Uli Kusterer
------------------------------------------------------------
"The Witnesses of TeachText are everywhere..."
http://www.zathras.de
_______________________________________________
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