Skip to content

Instantly share code, notes, and snippets.

@jlcampana
Created October 29, 2013 10:04
Show Gist options
  • Save jlcampana/7211873 to your computer and use it in GitHub Desktop.
Save jlcampana/7211873 to your computer and use it in GitHub Desktop.
meter un selector en un nsdictionary
SEL inSelector = @selector(something:);
NSString *selectorAsString = NSStringFromSelector(inSelector);
id dict = [[NSMutableDictionary alloc] initWithObjectsAndKeys:@"some text", @"text", selectorAsString, @"selector", nil];
// Retrieve selector
SEL outSelector = NSSelectorFromString([dict objectForKey:@"selector"]);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment