Re: Can a value transformer get its own registration name?
Re: Can a value transformer get its own registration name?
- Subject: Re: Can a value transformer get its own registration name?
- From: Jim Correia <email@hidden>
- Date: Thu, 12 Apr 2007 13:58:32 -0400
On Apr 12, 2007, at 1:33 PM, Bill Cheeseman wrote:
Of course I could do the same thing with multiple transformer
subclasses or,
as you pointed out, with a single subclass with a registered name
iVar to
use in the if-else chain. To my mind, the "generalized" subclass
approach
based on registered names and pointer comparisons is simpler to
implement,
both because I only need to write one subclass and I don't need to
mess with
iVars, -initWith... methods and all that. I just use the
registration naming
facility that NSValueTransformer already provides.
That's where we disagree. You only have to write one subclass. It it
just a matter of how you tell the instance how to do its work.
It is much easier, and straight forward, for an instance to have
those parameters directly available via iVars.
Trying to encode these in the registration name is not the way to go,
IMO. Especially given the considerations previously posted.
Jim
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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