Re: initializers in Categories?
Re: initializers in Categories?
- Subject: Re: initializers in Categories?
- From: "I. Savant" <email@hidden>
- Date: Thu, 13 Jul 2006 16:02:56 -0400
In this case, Ross, there's nothing to worry about really -
especially if you'd create a class method like [NSButton
robRossStyleButton] that instantiates a button and configures it to
your liking ... Create your (RobRossButtonAdditions) category and
fire away.
One caveat -- respect encapsulation. In other words, don't mess
with the iVars directly. Instead, you should use available methods
such as -setButtonStyle: etc.
--
I.S.
On Jul 13, 2006, at 3:54 PM, Rob Ross wrote:
The only thing I can think of at the moment is perhaps you have a
class with a lot of ivars and accessors, and you want to use a
group of them in some part of your code, and rather then having to
make a lot of [... setXXX] calls, create a convenience initializer
that will initialize the set of ivars you care about in one call.
_______________________________________________
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