最近想到了这些的东西,就去google搜索了一下,结果还真有,哈,知识在于发现,代码贴到下面了:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
NSLog(@"uniqueIdentifier: %@", [[UIDevice currentDevice] uniqueIdentifier]);
NSLog(@"name: %@", [[UIDevice currentDevice] name]);
NSLog(@"systemName: %@", [[UIDevice currentDevice] systemName]);
NSLog(@"systemVersion: %@", [[UIDevice currentDevice] systemVersion]);
NSLog(@"model: %@", [[UIDevice currentDevice] model]);
NSLog(@"localizedModel: %@", [[UIDevice currentDevice] localizedModel]);

NSDictionary *infoDictionary = [[NSBundle mainBundle] infoDictionary];

CFShow(infoDictionary);

// app名称
NSString *app_Name = [infoDictionary objectForKey:@"CFBundleDisplayName"];

// app版本
NSString *app_Version = [infoDictionary objectForKey:@"CFBundleShortVersionString"];

// app build版本
NSString *app_build = [infoDictionary objectForKey:@"CFBundleVersion"];