获取设备信息
NSLog(@"设备所有者 %@", [UIDevice currentDevice].name);
NSLog(@"设备类型 %@", [UIDevice currentDevice].model);
NSLog(@"本地化版本 %@", [UIDevice currentDevice].localizedModel);
NSLog(@"当前系统版本 %@", [UIDevice currentDevice].systemVersion);
NSLog(@"当前系统 %@", [UIDevice currentDevice].systemName);
NSLog(@"UUID %@", [[[UIDevice currentDevice] identifierForVendor] UUIDString]);
NSLog(@"电量 %f", [[UIDevice currentDevice] batteryLevel]); // -1为模拟器,0-1为真机
获取本地相关设置
NSArray *languageArray = [NSLocale preferredLanguages];
NSLog(@"语言: %@", [languageArray objectAtIndex:0]);
NSLocale *locale = [NSLocale currentLocale];
NSLog(@"国家: %@", [locale localeIdentifier]);
APP相关信息
NSDictionary *info = [[NSBundle mainBundle] infoDictionary];
NSLog(@"所有应用信息 %@", info);
NSLog(@"APP应用名称 %@", info[@"CFBundleDisplayName"]);
NSLog(@"APP应用版本 %@", info[@"CFBundleVersionString"]);
NSLog(@"APP应用Build版本 %@", info[@"CFBundleVersion"]);
NSLog(@"APP应用唯一标识 %@", info[@"CFBundleIdentifier"]);