【发布时间】:2016-03-06 15:09:39
【问题描述】:
在 Apple 的示例代码 AVCam-iOS: Using AVFoundation to Capture Images and Movies 中,我注意到以下行:
// Communicate with the session and other session objects on this queue.
self.sessionQueue = dispatch_queue_create( "session queue", DISPATCH_QUEUE_SERIAL );
我想知道第二个参数是关于什么的,除了DISPATCH_QUEUE_SERIAL,我们还有什么其他选择?
令人困惑的是,在其他 Apple 文档中,它说第二个参数是保留的,应该设置为 NULL。似乎文档已过时,谁能解释第二个参数应该是什么?
dispatch_queue_create 函数有两个参数:队列名称和一组队列属性。队列属性保留供将来使用,应为 NULL。 Concurrency Programming Guide
【问题讨论】:
标签: ios concurrency