Is there an equivalent of selectors for classes? How can I create a instance of a class from a string?
+7
A:
You want NSClassFromString
.
NSString *theClassForMe = @"NSMutableArray";
id newObject = [[NSClassFromString(theClassForMe) alloc] init];
Jim Puls
2009-06-23 18:41:08