Re: designing beyond MV and (one) C
Re: designing beyond MV and (one) C
- Subject: Re: designing beyond MV and (one) C
- From: Daniel Child <email@hidden>
- Date: Fri, 01 Feb 2008 13:10:10 -0500
I use categories to separate out additional methods beyond the basic
accessors and init / constructor / dealloc.
In this case, though, since there are different subclasses, a
separate strategies class seemed to work better. Thanks for the
suggestion, though, as it gives me an idea for reverse sorting with
arrays.
On Jan 27, 2008, at 2:09 PM, Sam Stigler wrote:
You might consider looking into categories. They let you add
methods to existing classes... for example, add an -appendDOCstring:
(NSData *)wordDocument method to NSMutableAttributedString. For
more, see http://developer.apple.com/documentation/Cocoa/Conceptual/
ObjectiveC/Articles/chapter_4_section_1.html . It might be more
convenient for you in the long run to write all of your parsers as
categories -- if not of NSMutableAttributedString, maybe of NSData.
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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:
This email sent to email@hidden