iOS如何获取设备相关信息

时间:2026-02-15 11:56:21

1、获取iPhone名称:

[UIDevice currentDevice].name;

iOS如何获取设备相关信息

2、获取app版本号:

[[[NSBundle mainBundle] infoDictionary] objectForKey:@"CFBundleShortVersionString"]

iOS如何获取设备相关信息

3、获取电池电量:

[UIDevice currentDevice].batteryLevel;

iOS如何获取设备相关信息

4、获取当前系统名称:

[UIDevice currentDevice].systemName;

iOS如何获取设备相关信息

5、获取当前系统版本号:

[UIDevice currentDevice].systemVersion;

iOS如何获取设备相关信息

6、获取UUID:

[[UIDevice currentDevice] identifierForVendor].UUIDString;

iOS如何获取设备相关信息

7、获取总内存大小:

[NSProcessInfo processInfo].physicalMemory;

iOS如何获取设备相关信息

8、获取当前语言:

NSArray *languageArray = [NSLocale preferredLanguages];

[languageArray objectAtIndex:0]

iOS如何获取设备相关信息

© 2026 途途旅游
信息来自网络 所有数据仅供参考
有疑问请联系站长 site.kefu@gmail.com