. I read the following site to remind me of
things to watch out for when submitting:
Avoiding iPhone App Rejection From Apple
And I read to remind me that many developers are frustrated with apple:
bk.addn/dev.mac/Cocoa Programming Developer's Handbook(free chapter):
David Chisnall goes through the most important aspects
of the OpenStep Foundation framework.,
which covers the core functionality of the Cocoa development environment.
. must be for the old version of the book I have;
all these corrections have been made in my edition .
proj.addn/dev.c/vc++ code editor: has code folding (yum) .
While Cygwin would be an obvious choice for
many Unix/Linux power users,
there is an excellent and a much simpler
alternative to using Cygwin
is using GNUWin32's coreutils .
. looking into that huge gnu collection
I notice he has indeed vastly simplified things
by getting just one of among dozens of packages .
. getting the entire gnuwin32 collection
would be as complicated as cygwin
and for that case, they use cygwin's approach:
an installer app that gets the latest version of each package .
. reviewing the code,
I see it's nicely commented,
but some can seem overly complicated by the use of
conditional compilation directives .
. Chapter 1: Introducing Pylons — Pylons Book v1.1 documentation
. their example comes as a before&after version of the same project,
and I'm using winmerge to see the diff's side-by-side .
Cocoa Design Patterns By Erik Buck and Don Yacktman
Voices that Matter
Materials from Erik's talk at the Voices that Matter - iPhone Developers Conference
Sample Code for Cocoa Design Patterns.
Sample Code > Voices that Matter
Cocoa Design Patterns.pdf (2.7M)
OpenGL ES for iPhone Games.pdf (1.6M)
2.17: web.addn/dev.mac/cocoa patterns ref's to stepwise:
see cocoa page 111 for todo.web.
I just read the new article on Stepwise about Cocoa
memory management by Manu Iyengar
(which is very well done, by the way). In it, he presents the
following code as a useful idiom for writing set accessor methods.
> - (void) setTheory: (Theory *)newTheory
> Theory *oldTheory = nil;
> if ( theory != newTheory ) // If they're the same,
> [self willChange]; // For Enterprise
> oldTheory = theory; // Copy the reference
> theory = [newTheory retain];// First retain the new object
> [oldTheory release]; // Then release the old object
I'm new to Cocoa and I'd like to adopt as many useful idioms as I
can find. There seem to be many with regard to writing set accessor
functions...;-) What are the pros and cons of the code above
compared to other set accessor idioms I've seen, like this:
- (void) setTheory: (Theory*)newTheory
if ( theory != newTheory )
theory = [newTheory retain];
William Garrison wrote:
>In particular, why would I want to create a temporary pointer to the
>existing ivar value before setting it to the new value? Manu's
>example uses a basic swap pattern, but I don't know why that would be
>useful. Why can't I just release the existing ivar object and then
>retain the new value, as the second code example does?
Multithreading. There's a very small but still very real chance that
the current thread might be switched between the release and the new
assignment, so another thread might try to access the just released
(and maybe deallocated!) object and go boom
Alternatively you could use a simple lock but that's overkill for
the 99% percent when you don't need it.
>Would using autorelease instead of release be another way to protect against
>this? After all, the old object wouldn't be up for a real release until
>after the new object is retained.
Sure, but then you'd have to pay for the autorelease each time, which
is much more expensive than a second reference (memory and cycles-wise).
There ain't no free lunch. :)
lib.addn/dev.mac/www.stepwise.com articles archived:
. site:www.stepwise.com/Articles was not easy to find before,
but did ok this time:
. HoldMe.html is the mem'mgt tutorial recommended by buck`patterns .
proj.addn/dev.mac/doc's copied to xpw:
. explore mac's dev/doc's ...
can't find as expected?
because, they seem to be in a special archive format:
use downloads instead:
. zip cocoa doc's to xpw (the downloaded pdf's) .
. by context menu this is seen as a type of folder;
everything is html .
2.25: aq.addn/dev.mac#iPhone/app review/CrazyMikesapps.com