u_int count;
objc_property_t *properties =class_copyPropertyList([UIview class], &count);
NSMutableArray *propertiesArray = [NSMutableArray arrayWithCapacity:count];
for (int i = 0; i<count; i++)
{
const char* propertyName =property_getName(properties[i]);
NSLog(@"属性%@\n",[NSString stringWithUTF8String: propertyName]);
[propertiesArray addObject: [NSString stringWithUTF8String: propertyName]];
}
遍历控件属性
最新推荐文章于 2022-03-17 10:40:15 发布