GCD
2016-01-28 10:01
344 查看
dispatch_queue_t queue=dispatch_queue_create("luoliping", DISPATCH_QUEUE_SERIAL); dispatch_async(queue, ^{ NSLog(@"%@",[NSThread currentThread]); }); dispatch_suspend(queue); dispatch_resume(queue); dispatch_async(queue, ^{ NSLog(@"%@",[NSThread currentThread]); }); dispatch_async(queue, ^{ NSLog(@"%@",[NSThread currentThread]); }); dispatch_async(dispatch_get_global_queue(0, 0), ^{ NSLog(@"2-%d",[NSThread isMainThread]); dispatch_async(dispatch_get_main_queue(), ^{ NSLog(@"2-%d",[NSThread isMainThread]); //刷新表 [_tableView reloadData]; }); });
相关文章推荐
- Squid 操作实践
- Jquery DataTables 自定义布局
- android 调用 dexopt 的位置
- Squid 操作实践
- vim工具链环境搭建
- kmp算法
- 小小白初入编程江湖之初入职场迷茫篇
- static_cast、dynamic_cast、const_cast和reinterpret_cast总结
- Codeforces Round #340 (Div. 2) C. Watering Flowers
- 控制摄像头拍照(一)
- linux 性能测试
- 一种SpringMVC调用Javascript的方法
- Android 6.0: 动态权限管理的解决方案
- 工作流之-流程中设计到的表
- 微信公众号被动回复两条消息(一条正常,一条暂无法提供服务)
- bootstrap3 兼容IE8浏览器
- opencv基础知识-videowriter
- pdo_mysql安装
- svnserver配置文件详解一
- ToolBar