Linked by Eugenia Loli-Queru on Mon 24th May 2004 06:48 UTC
Mac OS X More than two years ago we reviewed the first edition of the excellent book by Aaron Hillegass, "Cocoa Programming for Mac OS X". The second edition has just being released and we will be taking a quick look as to what's new.
Permalink for comment
To read all comments associated with this story, please click here.
re: threehits
by John Timmer on Mon 24th May 2004 12:44 UTC

Like most people who have been using Cocoa since it was NeXT, the author believes ObjC is THE ANSWER, so it's not surprising that he recommends it. At the time of the first edition, there were still a lot of bugs in the Java/ObjC bridge, so he justifiably recommended against using Java with Cocoa. My understanding is that a lot of those bugs have been squashed, so there's less reason to avoid it. That said, Java apps launch slowly because they have to wait for its runtime to launch, and Cocoa was designed for use with ObjC, so it will always be a better fit with that language.

Going with GCJ won't help with most of these issues, because they are language issues, not compiler issues. An example off the top of my head is that lots of things in Cocoa still use C-style structs (ie - window areas are defined as a rectangular "frame" struct with an origin and size, which are in turn both structs). Since Java doesn't allow primitives like this, the whole thing has to be reworked and new classes created to handle these things.

Cheers,

JT