I'm refactoring and updating a lot of my older code, and one of the
things I'm finally looking into is declaring things as properties.

But...what's the point? I've been trying to read up on the subject and
have found a lot of posts and discussion about the subject, but very
little of it seems to get down to the meat of what these things are
and why I should care about them.

At the simplest level, I just look at them as some syntactic sugar. So
I get to write one @property line in my @interface and one @synthesize
line in my @implementation (assuming no more complicated behavior, of
course). So it's nifty in that I save myself a lot of redundant
typing, but realistically? I could accomplish the same thing with a
preprocessor macro and have more fine grained control over exactly how
my generated methods look. I mean, it's cool and all that it's built
in and saves me from writing my own macro, but realistically this
isn't terribly interesting.

I know I'd get use of the dot syntax (I do need to use @properties to
do that, right?), but I'm eschewing it anyway. Again, I've seen all
sorts of arguments about people disliking it because it's not
objective-Cish or confusion about structs or whatever, but for me, I
simply just don't care to use it. I've got lots of existing code that
uses methods and I don't see any reason to update. I'm just a stick in
the mud sometimes.

So basically, I get a language built-in version of a macro, and an
option to use a new syntax that I'm not interested in anyway.

Is there something else I'm not seeing or some other utility to them
that I don't yet understand?

-Jim.....
_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to