Re: Passing a SEL into KVC
Re: Passing a SEL into KVC
- Subject: Re: Passing a SEL into KVC
- From: Hank Heijink <email@hidden>
- Date: Wed, 6 Dec 2006 13:25:00 -0500
I think the easiest way is to convert the SEL to a string.
[self setValue:NSStringFromSelector(@selector(someMethod:))
forKey:@"selectorTest"]
And back with NSSelectorFromString.
On Dec 6, 2006, at 1:14 PM, Marcus S. Zarra wrote:
Is there any way to pass a SEL into kvc?
For example:
SEL test = @selector(someMethod:);
[self setValue:test forKey:@"selectorTest"];
Hank Heijink
www.hankheijink.com
email@hidden
_______________________________________________
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