2018-07-16

调试相关

About Debugging with Xcode

About LLDB and Debugging
LLDB Quick Start Guide

苹果审核

App Store Review Guidelines

Universal Link

App Search Programming Guide

iOS 9学习系列:打通 iOS 9 的通用链接(Universal Links)

直接按照《iOS 9学习系列:打通 iOS 9 的通用链接(Universal Links)》里面的操作就可以,需要特别强调的一点是:如果不支持 https, apple-app-site-association 文件一定要使用 ssl 签名;https:///apple-app-site-association 或者https:///.well-known/apple-app-site-association 二选一即可

如果之前的 apple-app-site-association 文件有问题,你修改了,并且修改了 apple-app-site-association 的存放位置,一定一定要告诉服务器删除原来的!!!!

使用 JavaScript 也可以实现打开一个连接可以跳转到一个 app(window.location = “justalk://path”),但是这里有几点不一样:
1. 这种方式在 Safari 每次都有提醒,用户体验不是很好
[图片上传失败...(image-e7b214-1531721262865)]

当然,如果是用户点击的按钮触发的跳转就不会有这个问题
<a href="justalk://path">Jump to JusTalk</a>
2. 这种方式会在 Safari 留下一个空白的页面

这里还有些第三方资源

Branch(免费第三方 Deep Link 和 Deferred Deep Link)
Branch SDK 实现源码

iOS 中的 Deferred Deep Linking(延迟深度链接)
你知道App推广神技“Deferred Deeplink”吗?
Deferred Deep Linking in iOS
Android: Handling App Links
Facebook 推出 App Links 开发者工具意在解决什么问题?

内购相关(IAP)

In-App Purchase Configuration Guide for iTunes Connect

In-App Purchase Programming Guide
Adding In-App Purchase to your Applications
Introducing Expanded Subscriptions in iTunes Connect (WWDC 2016)

需要注意的是:
1. 如果应用没有审核通过,那么这次提交审核的商品的 ID 就不能再使用,需要重新创建新的商品
2. 应用里面要提供 term of use 和用户协议。用户可以查看到这些内容。如果没有会直接被拒

iOS Human Interface Guidelines

包含不同设计元素的设计原则和尺寸
拓展功能相关的元素和设计原则(如:3D Touch、Spotlight 等)
新的 iOS 版本更新了哪些设计元素和设计原则

iOS Auto Layout Guide

auto layout 最终还是通过对约束的计算来修改 view 的 frame 来实现对控件大小和位置的控制。
需要注意的是,view 中的 transform 也是通过修改 frame 来实现 transfrom 的效果。但是 transform 并不会修改 bounds。auto layout 在计算新的 frame 时也不会参考 transform 属性,即** transform 对 auto layout 无效**

深入剖析Auto Layout,分析iOS各版本新增特性

Resource Programming Guide

包括 Nib 工作流程和原理,nib 相关概念(file owner、first responder 等)。图片、字符串、多媒体资源的使用等

iCloud 编程

CloudKit Quick Start

iCloud Design Guide

Extension And Widget

App Extension Programming Guide
包括自定义键盘,Widget 等

Wallet Developer Guide
包括自定义键盘,Widget 等

Document Interaction Programming Topics for iOS(UTI)

Document Interaction Programming Topics for iOS
iOS实现App之间的内容分享

音视频相关

Audio Unit Hosting Guide for iOS
Core Audio Overview
Core Audio Glossary

iOS开发系列–音频播放、录音、视频播放、拍照、视频录制
使用AV Foundation从摄像头将视频帧捕获为图像
一篇对iOS音频比较完善的文章
oc开发笔记3 录音时频率获取 以及声像显示

iOS Dual Camera 相关
包括相机校正信息、深度信息、广角和长焦图片获取等

func depthDataMap() -> CVPixelBuffer? {

  // 1
  guard let fileURL = Bundle.main.url(forResource: name, withExtension: ext) as CFURL? else {
    return nil
  }

  // 2
  guard let source = CGImageSourceCreateWithURL(fileURL, nil) else {
    return nil
  }

  // 3
  guard let auxDataInfo = CGImageSourceCopyAuxiliaryDataInfoAtIndex(source, 0, 
      kCGImageAuxiliaryDataTypeDisparity) as? [AnyHashable : Any] else {
    return nil
  }

  // 4
  var depthData: AVDepthData

  do {
    // 5
    depthData = try AVDepthData(fromDictionaryRepresentation: auxDataInfo)

  } catch {
    return nil
  }

  // 6
  if depthData.depthDataType != kCVPixelFormatType_DisparityFloat32 {
    depthData = depthData.converting(toDepthDataType: kCVPixelFormatType_DisparityFloat32)
  }

  // 7
  return depthData.depthDataMap
}
// 1
let depthReader = DepthReader(name: name, ext: ext)

// 2
let depthDataMap = depthReader.depthDataMap()

// 3
depthDataMap?.normalize()

// 4
let ciImage = CIImage(cvPixelBuffer: depthDataMap)
depthDataMapImage = UIImage(ciImage: ciImage)

Core Animation Programming Guide

包含了动画机制,使用教程,以及有哪些 keyPath 可以使用。详见章节《Key Path Support for Structures》

Quartz 2D Programming Guide

绘图相关的所有知识。包括涂鸦的实现(详见《Setting Blend Modes》)图片的变换(详见《Transforms》)

通过下面的代码可以把 UIKit 坐标转换成 2D 绘图坐标系

CGAffineTransform transform = CGAffineTransformIdentity;
transform.a = 1;
transform.b = 0;
transform.c = 0;
transform.d = -1;
transform.tx = 0;
transform.ty = CGBitmapContextGetHeight(context);
// 对应的是 2D 绘图坐标系下的值
frame = CGRectApplyAffineTransform(frame, transform);

关于仿射变换可以参照如何通俗地讲解「仿射变换」这个概念?以及章节Transforms

Local and Remote Notification Programming Guide

包含了接口说明和 APNs 机制

访问系统通讯录数据

iOS7 - iOS 9
iOS10
Address Book Programming Guide for iOS

KeyChain

Keychain Services Programming Guide

使用 KeyChain 的时候有以下几点需要注意:
1. In iOS, Keychain rights depend on the provisioning profile used to sign your application. Be sure to consistently use the same provisioning profile across different versions of your application.
2. An app with a minimum deployment target earlier than iOS 8.0 cannot use application groups for keychain item sharing, and should instead rely on the keychain-access-groups entitlement to share keychain items.
3. When your app creates a keychain item, if you do not explicitly specify the kSecAttrAccessGroup key in the item’s attributes dictionary, Keychain Services uses the first group of the app’s access groups array (ordered as shown above) as the default access group. If your app has a keychain-access-groups entitlement, Keychain Services uses the first of these. Otherwise, it uses the application identifier, which is always present. Thus, by default, unless you add a keychain-access-groups entitlement, an app creates keychain items to which only it has access. On the other hand, all the named access groups from the collection above are valid values for the kSecAttrAccessGroup key. This allows you to add new items to any one of the app’s groups.
4. SecItemAdd 等方法会返回 OSStatus 类型的结果,返回值的含义可以参照 SecBase.h
5. KeyChain 中 kSecAttrGeneric 的作用类似于 identifier。当添加一条记录某一(A)的时候,如果 KeyChain 中有一条记录(B)和 A 有相同的 kSecAttrGeneric ,并且 A 和 B 的属性种类也完全相同,那么这个时候使用 Add 方法会失败,应该使用 Update 方法。

// add
NSMutableDictionary *dic = [NSMutableDictionary dictionary];
    [dic setObject:(__bridge id)kSecClassGenericPassword forKey:(__bridge id)kSecClass];
    [dic setObject:[@"11223344" dataUsingEncoding:NSUTF8StringEncoding] forKey:(__bridge id)kSecAttrGeneric];
    [dic setObject:@"1122334466" forKey:(__bridge id)kSecAttrAccount];
    [dic setObject:[@"1122334455" dataUsingEncoding:NSUTF8StringEncoding] forKey:(__bridge id)kSecAttrService];
    [dic setObject:(__bridge id)kCFBooleanFalse forKey:(__bridge id)kSecReturnData];
    OSStatus status = SecItemAdd((__bridge CFDictionaryRef)dic, NULL);
// match
// 匹配条件是 kSecClass 为 kSecClassGenericPassword
// 并且 kSecAttrGeneric 为 [@"11223344" dataUsingEncoding:NSUTF8StringEncoding]
// 同时其他属性中包含 [@"112233" dataUsingEncoding:NSUTF8StringEncoding]
NSMutableDictionary *dic2 = [NSMutableDictionary dictionary];
    [dic2 setObject:(__bridge id)kSecClassGenericPassword forKey:(__bridge id)kSecClass];
    [dic2 setObject:[@"11223344" dataUsingEncoding:NSUTF8StringEncoding] forKey:(__bridge id)kSecAttrGeneric];
    [dic2 setObject:[@"112233" dataUsingEncoding:NSUTF8StringEncoding] forKey:(__bridge id)kSecMatchSubjectContains];
    [dic2 setObject:(__bridge id)kSecMatchLimitAll forKey:(__bridge id)kSecMatchLimit];
    [dic2 setObject:(__bridge id)kCFBooleanTrue forKey:(__bridge id)kSecReturnAttributes];
    CFTypeRef outPut = NULL;
    OSStatus status2 = SecItemCopyMatching((__bridge CFDictionaryRef)dic2, (CFTypeRef *) &outPut);

多线程

Runtime

  • Runtime 函数列表
    Runtime 相关函数列表及含义

  • Type Encodings
    runtime 情况下不同数据类型对应的类型列表。如:c 代表 char 类型,i 代表 int 类型等

APP 发布

App Distribution Guide

  • 包含了证书相关的知识,以及如何配置工程来出版本等
  • 查看 APP 中 provision 的 entitlements

iTunes Connect 开发人员帮助
itunesconnect 使用帮助。包括 App Store 图标规范等

App Programming Guide for iOS
工程配置(包括必须的资源等)、生命周期、后台原理等

On-Demand Resources Guide
如何使用 On-Demand 方式来动态加载应用中需要的资源来减小下载包大小

Bundle Programming Guide
程序、framework等都是 Bundle 只是类型不同

iOS 7 UI Transition Guide

包含 iOS 7 更新了哪些东西,怎样从之前的版本过度到 iOS 7
例如: wantsFullScreenLayout、edgesForExtendedLayout、extendedLayoutIncludesOpaqueBars、automaticallyAdjustsScrollViewInsets 等

Information Property List Key Reference

iOS 中 info.plist 用的 property key 及含义

文字处理

©著作权归作者所有,转载或内容合作请联系作者
  • 序言:七十年代末,一起剥皮案震惊了整个滨河市,随后出现的几起案子,更是在滨河造成了极大的恐慌,老刑警刘岩,带你破解...
    沈念sama阅读 162,825评论 4 377
  • 序言:滨河连续发生了三起死亡事件,死亡现场离奇诡异,居然都是意外死亡,警方通过查阅死者的电脑和手机,发现死者居然都...
    沈念sama阅读 68,887评论 2 308
  • 文/潘晓璐 我一进店门,熙熙楼的掌柜王于贵愁眉苦脸地迎上来,“玉大人,你说我怎么就摊上这事。” “怎么了?”我有些...
    开封第一讲书人阅读 112,425评论 0 255
  • 文/不坏的土叔 我叫张陵,是天一观的道长。 经常有香客问我,道长,这世上最难降的妖魔是什么? 我笑而不...
    开封第一讲书人阅读 44,801评论 0 224
  • 正文 为了忘掉前任,我火速办了婚礼,结果婚礼上,老公的妹妹穿的比我还像新娘。我一直安慰自己,他们只是感情好,可当我...
    茶点故事阅读 53,252评论 3 299
  • 文/花漫 我一把揭开白布。 她就那样静静地躺着,像睡着了一般。 火红的嫁衣衬着肌肤如雪。 梳的纹丝不乱的头发上,一...
    开封第一讲书人阅读 41,089评论 1 226
  • 那天,我揣着相机与录音,去河边找鬼。 笑死,一个胖子当着我的面吹牛,可吹牛的内容都是我干的。 我是一名探鬼主播,决...
    沈念sama阅读 32,216评论 2 322
  • 文/苍兰香墨 我猛地睁开眼,长吁一口气:“原来是场噩梦啊……” “哼!你这毒妇竟也来了?” 一声冷哼从身侧响起,我...
    开封第一讲书人阅读 31,005评论 0 215
  • 序言:老挝万荣一对情侣失踪,失踪者是张志新(化名)和其女友刘颖,没想到半个月后,有当地人在树林里发现了一具尸体,经...
    沈念sama阅读 34,747评论 1 250
  • 正文 独居荒郊野岭守林人离奇死亡,尸身上长有42处带血的脓包…… 初始之章·张勋 以下内容为张勋视角 年9月15日...
    茶点故事阅读 30,883评论 2 255
  • 正文 我和宋清朗相恋三年,在试婚纱的时候发现自己被绿了。 大学时的朋友给我发了我未婚夫和他白月光在一起吃饭的照片。...
    茶点故事阅读 32,354评论 1 265
  • 序言:一个原本活蹦乱跳的男人离奇死亡,死状恐怖,灵堂内的尸体忽然破棺而出,到底是诈尸还是另有隐情,我是刑警宁泽,带...
    沈念sama阅读 28,694评论 3 265
  • 正文 年R本政府宣布,位于F岛的核电站,受9级特大地震影响,放射性物质发生泄漏。R本人自食恶果不足惜,却给世界环境...
    茶点故事阅读 33,406评论 3 246
  • 文/蒙蒙 一、第九天 我趴在偏房一处隐蔽的房顶上张望。 院中可真热闹,春花似锦、人声如沸。这庄子的主人今日做“春日...
    开封第一讲书人阅读 26,222评论 0 9
  • 文/苍兰香墨 我抬头看了看天上的太阳。三九已至,却和暖如春,着一层夹袄步出监牢的瞬间,已是汗流浃背。 一阵脚步声响...
    开封第一讲书人阅读 26,996评论 0 201
  • 我被黑心中介骗来泰国打工, 没想到刚下飞机就差点儿被人妖公主榨干…… 1. 我叫王不留,地道东北人。 一个月前我还...
    沈念sama阅读 36,242评论 2 287
  • 正文 我出身青楼,却偏偏与公主长得像,于是被迫代替她去往敌国和亲。 传闻我的和亲对象是个残疾皇子,可洞房花烛夜当晚...
    茶点故事阅读 36,017评论 2 281

推荐阅读更多精彩内容

  • 1、通过CocoaPods安装项目名称项目信息 AFNetworking网络请求组件 FMDB本地数据库组件 SD...
    X先生_未知数的X阅读 15,937评论 3 118
  • 大家好,今天是2017年6月28日,白天还是艳阳高照的天空到了下班时刻,电闪雷鸣,下起了大暴雨。刚被...
    陶壹阅读 296评论 0 1
  • 慈寿塔和天下第一泉 图上那一个塔,那是为慈禧祝寿的慈寿塔,照相处据观察应该是从天下第一泉那里照过来,其实天下第一泉...
    勳君阅读 338评论 2 3
  • 不知道怎么介绍自己,人到中年,活得好像稀里糊涂的,不谙世事,简简单单,年纪不小,心理测试还是年轻,哎,不...
    kitty2017阅读 243评论 0 0
  • 一个“分”字道出了昼夜、寒暑的界限。 此时气温忽冷忽热,人体的阴阳也容易因此而失去平衡。中医来讲,阴阳平衡了,就会...
    茶之心阅读 389评论 0 0