Class themeClass = NSClassFromString(@"YourClassName");
unsigned int outCount = 0;
Method *methodList = class_copyMethodList(themeClass, &outCount);
for (int i = 0; i < outCount; i++) {
Method method = methodList[i];
const char *name = sel_getName(method_getName(method));
NSLog(@"method: %s", name);
}
id manager = [[themeClass alloc] init];
//po [manager _methodDescription]
NSObject *theme = [pkClass performSelector:@selector(sharedThemeManager)];
if (theme) {
NSLog(@"available");
}
网友评论