一、获取UiDevice设备信息

// 获取设备名称
NSString *name = [[UIDevice currentDevice] name];
// 获取设备系统名称
NSString *systemName = [[UIDevice currentDevice] systemName];
// 获取系统版本
NSString *systemVersion = [[UIDevice currentDevice] systemVersion];
// 获取设备模型
NSString *model = [[UIDevice currentDevice] model];
// 获取设备本地模型
NSString *localizedModel = [[UIDevice currentDevice] localizedModel];

二、获取Bundle的相关信息

NSDictionary *infoDict = [[NSBundle mainBundle] infoDictionary];
// app名称
NSString *appName = infoDict[@"CFBundleName"];
// app版本
NSString *appVersion = infoDict[@"CFBundleShortVersionString"];
// app build版本
NSString *appBuild = infoDict[@"CFBundleVersion"];

NSLocal获取本地化数据:

// 获取用户的语言偏好设置列表
NSLog(@"%@", [NSLocale preferredLanguages]); // 获取系统所有本地化标识符数组列表
NSLog(@"%@", [NSLocale availableLocaleIdentifiers]);
// 获取所有已知合法的国家代码数组列表
NSLog(@"%@", [NSLocale ISOCountryCodes]);
// 获取所有已知合法的ISO货币代码数组列表
NSLog(@"%@", [NSLocale ISOCurrencyCodes]);
// 获取所有已知合法的ISO语言代码数组列表
NSLog(@"%@", [NSLocale ISOLanguageCodes]); // 获取当前系统设置语言的标识符
// 方法一
NSLog(@"%@", [[NSLocale currentLocale] localeIdentifier]);
// 方法二
NSLog(@"%@", [[NSLocale currentLocale] objectForKey:NSLocaleIdentifier]);

iOS开发-Object-C获取手机设备信息(UIDevice)的更多相关文章

  1. iOS开发-Swift获取手机设备信息(UIDevice)

    使用UiDevice获取设备信息 获取设备名称 let name = UIDevice.currentDevice().name 获取设备系统名称 let systemName = UIDevice. ...

  2. 【转】android 安卓APP获取手机设备信息和手机号码的代码示例

    http://blog.csdn.net/changemyself/article/details/7421476 下面我从安卓开发的角度,简单写一下如何获取手机设备信息和手机号码 准备条件:一部安卓 ...

  3. android 安卓APP获取手机设备信息和手机号码的代码示例

    下面我从安卓开发的角度,简单写一下如何获取手机设备信息和手机号码 准备条件:一部安卓手机.手机SIM卡确保插入手机里.eclipse ADT和android-sdk开发环境 第一步:新建一个andro ...

  4. ?Object-C获取手机设备信息

    一.获取UiDevice设备信息 // 获取设备名称 NSString *name = [[UIDevice currentDevice] name]; // 获取设备系统名称 NSString *s ...

  5. ?Swift获取手机设备信息

    使用UiDevice获取设备信息: 获取设备名称 let name = UIDevice.currentDevice().name 获取设备系统名称 let systemName = UIDevice ...

  6. android -------- 获取手机设备信息

    最近在开发中,需要用到一些系统信息,总结了一下 /** * Created by zhangqie on 2019/2/26 * Describe: 系统工具类 */ public class Equ ...

  7. ios 获取手机设备信息

    [UIDevice currentDevice]:表示设备 NSString *devices=[[NSString alloc] initWithFormat: @"unique id: ...

  8. java翻译到mono C#实现系列(3) 获取手机设备信息(残缺,)

    using System; using Android.App; using Android.Content; using Android.Runtime; using Android.Views; ...

  9. Android获取手机设备识别码(IMEI)和手机号码

    最近看了下获取手机设备ID和手机信息以及SIM的信息例子,主要还是借鉴别人的,现在自己写一下,算是巩固加深了,也希望能给大家一个参考 必要的条件还是一部真机,SIM卡或者UIM卡. 首先,在Andro ...

随机推荐

  1. css过渡笔记

    3D     http://fangyexu.com/tool-CSS3Inspector.html <!DOCTYPE html> <html lang="en" ...

  2. angularjs -- 路由监听

    前几天,项目在做一个功能时需要在页面切换之前关闭正在执行的函数.尝试了几种方式都不行,最后想到既然angularjs是通过理由切换页面,那就在路由上面做文章吧.AngularJS在路由发生改变时,可以 ...

  3. ubuntu14.04 忘记了登录密码和root密码

    由于很久没用自己的ubuntu了,发现刚想用时却忘记了密码,搞了半天终于搞好了,真的.... 在此记录一下自己的新密码:登录密码:1234567:ROOT密码:1234567 下面是整理网上的教程,亲 ...

  4. 【转】grep -v grep

    1.grep 是查找含有指定文本行的意思,比如grep test 就是查找含有test的文本的行 2.grep -v 是反向查找的意思,比如 grep -v grep 就是查找不含有 grep 字段的 ...

  5. 6.Spring MVC SSM整合问题总结

    1.Cannot find class [org.springframework.http.converter.json.MappingJacksonHttpMessageConverter] for ...

  6. 【gp数据库】查询系统表看模式下所有表的分布键信息

    Greenplum是关系型的分布式数据库,需要存储的数据库在进入数据库时,将先进行数据分布的处理工作,讲一个表的数据平均分不到每个节点上,并为每个表指定一个分发列(distribute Column) ...

  7. 【Redis】命令学习笔记——键(key)(20个超全字典版)

    安装完redis和redis-desktop-manager后,开始学习命令啦!本篇基于redis 4.0.11版本,从对键(key)开始挖坑! 准备工作,使用db1(默认db0,由于之前练习用db0 ...

  8. Docker 报错 error during connect: Get pipe/docker_engine: The system cannot find the file specified. - 摘要: 本文讲的是Docker 报错 error during connect: Get pipe/dock

    error during connect: Get http://%2F%2F.%2Fpipe%2Fdocker_engine/v1.37/version: open //./pipe/docker_ ...

  9. 上拉加载下拉刷新控件WaterRefreshLoadMoreView

    上拉加载下拉刷新控件WaterRefreshLoadMoreView 效果: 源码: // // SRSlimeView // @author SR // Modified by JunHan on ...

  10. 【原创】Qt 使用ODBC driver 连接SQL Server

    最近在做数据库的课程设计.第一个需要解决的问题是使用什么工具来实现这个系统.经过一番资料查找,决定使用SQL Server Express 2012作为服务器,使用Qt作为编写客户端程序语言.问题是c ...