Theocacao
Leopard
Design Element
Comment on "A Quick Objective-C 2.0 Tutorial"
by Gav Newalkar — Jan 24
Hi there,

I've started to learn objective-C / cocoa and i'm from a strong Java background.

One of my major gripes with objective-c is that you define instance variables within the interface. This goes against what i've learnt, which is that instance variables are implementation details.

What if i want to implement a class with my own set of instance variables? Can i define them in the interface section or am I forced to creat a sub-class?

Moreso, what is the motive behine Apple to so this way in making developers specify instance variables within an interface?

Gav
Back to "A Quick Objective-C 2.0 Tutorial"
Design Element

Copyright © Scott Stevenson 2004-2015