没有合适的资源?快使用搜索试试~ 我知道了~
首页iOS 7应用开发入门指南
iOS 7应用开发入门指南
5星 · 超过95%的资源 需积分: 9 38 下载量 13 浏览量
更新于2024-07-24
2
收藏 14.47MB PDF 举报
《iOS7 App Development Essentials》是一本专为iOS 7和Xcode 5新手以及有一定经验的iOS 6开发者编写的入门书籍。本书的首要目标是帮助读者掌握iOS 7应用程序开发的基础知识,以适应苹果公司的最新技术和平台变化。作者Neil Smyth确保了内容针对iOS 7的新特性和API进行了详尽的讲解,适合那些希望提升技能或初次接触iOS开发的读者。
对于新iOS开发者,章节1(Start Here)旨在提供一个全面的入门指南,介绍了iOS开发的基本概念、环境设置以及如何使用Swift或Objective-C这两种主要编程语言。该部分可能涵盖了故事板设计、视图控制器、数据存储和网络请求等基础知识,帮助读者建立坚实的开发基础。
对于已经熟悉iOS 6的开发者,章节1.2将着重于向他们介绍iOS 7的新特性,比如新的用户界面设计、改进的动画效果、以及API升级,旨在帮助他们在快速变化的平台上保持竞争力。
源代码下载部分(1.3)提供了实践学习的机会,让读者可以直接查看和运行书中的示例代码,以便更快地理解和应用理论知识。此外,作者还鼓励读者提供反馈(1.4),以便不断更新和完善内容,确保信息的准确性和时效性。
书中还包含了关于苹果iOS开发者计划的介绍(2.1),指导读者如何注册成为合法的Apple Developer,并下载Xcode和iOS 7软件开发工具包(SDK),这对于任何想要在App Store上发布应用的人来说都是必不可少的步骤。
最后,1.5部分列出了可能存在的错误和遗漏,以便读者及时修正,保证学习的连贯性和有效性。《iOS7 App Development Essentials》是一本既适合初学者入门,也适合有一定经验开发者提升的实用教程,内容丰富,针对性强,对于iOS开发者来说是一份宝贵的参考资料。
xvi
41.2 Managed Objects ............................................................................................................. 366
41.3 Managed Object Context ................................................................................................. 366
41.4 Managed Object Model .................................................................................................... 367
41.5 Persistent Store Coordinator ............................................................................................ 367
41.6 Persistent Object Store..................................................................................................... 368
41.7 Defining an Entity Description .......................................................................................... 368
41.8 Obtaining the Managed Object Context .......................................................................... 369
41.9 Getting an Entity Description ........................................................................................... 370
41.10 Creating a Managed Object ............................................................................................ 370
41.11 Getting and Setting the Attributes of a Managed Object .............................................. 370
41.12 Fetching Managed Objects ............................................................................................. 371
41.13 Retrieving Managed Objects based on Criteria .............................................................. 371
41.14 Summary ........................................................................................................................ 372
42. An iOS 7 Core Data Tutorial ............................................................................................... 373
42.1 The Core Data Example Application ................................................................................. 373
42.2 Creating a Core Data based Application ........................................................................... 373
42.3 Creating the Entity Description ........................................................................................ 373
42.4 Adding a Storyboard to the Project .................................................................................. 375
42.5 Adding a View Controller .................................................................................................. 376
42.6 Designing the User Interface ............................................................................................ 376
42.7 Saving Data to the Persistent Store using Core Data ....................................................... 378
42.8 Retrieving Data from the Persistent Store using Core Data ............................................. 379
42.9 Building and Running the Example Application................................................................ 380
42.10 Summary ........................................................................................................................ 381
43. An Overview of iOS 7 Multitouch, Taps and Gestures ....................................................... 383
43.1 The Responder Chain ....................................................................................................... 383
43.2 Forwarding an Event to the Next Responder ................................................................... 384
43.3 Gestures ........................................................................................................................... 384
43.4 Taps .................................................................................................................................. 384
43.5 Touches ............................................................................................................................ 385
43.6 Touch Notification Methods ............................................................................................. 385
43.6.1 touchesBegan method .............................................................................................. 385
43.6.2 touchesMoved method ............................................................................................. 385
43.6.3 touchesEnded method .............................................................................................. 385
43.6.4 touchesCancelled method ......................................................................................... 386
43.7 Summary .......................................................................................................................... 386
xvii
44. An Example iOS 7 Touch, Multitouch and Tap Application ................................................ 387
44.1 The Example iOS 7 Tap and Touch Application ................................................................ 387
44.2 Creating the Example iOS Touch Project .......................................................................... 387
44.3 Designing the User Interface ............................................................................................ 387
44.4 Enabling Multitouch on the View ..................................................................................... 389
44.5 Implementing the touchesBegan Method ....................................................................... 389
44.6 Implementing the touchesMoved Method ...................................................................... 390
44.7 Implementing the touchesEnded Method ....................................................................... 390
44.8 Getting the Coordinates of a Touch ................................................................................. 391
44.9 Building and Running the Touch Example Application ..................................................... 391
45. Detecting iOS 7 Touch Screen Gesture Motions ................................................................ 393
45.1 The Example iOS 7 Gesture Application ........................................................................... 393
45.2 Creating the Example Project ........................................................................................... 393
45.3 Designing the Application User Interface ......................................................................... 393
45.4 Implementing the touchesBegan Method ....................................................................... 395
45.5 Implementing the touchesMoved Method ...................................................................... 395
45.6 Implementing the touchesEnded Method ....................................................................... 396
45.7 Building and Running the Gesture Example ..................................................................... 396
45.8 Summary .......................................................................................................................... 396
46. Identifying Gestures using iOS 7 Gesture Recognizers ....................................................... 397
46.1 The UIGestureRecognizer Class ........................................................................................ 397
46.2 Recognizer Action Messages ............................................................................................ 398
46.3 Discrete and Continuous Gestures ................................................................................... 398
46.4 Obtaining Data from a Gesture ........................................................................................ 398
46.5 Recognizing Tap Gestures ................................................................................................ 399
46.6 Recognizing Pinch Gestures .............................................................................................. 399
46.7 Detecting Rotation Gestures ............................................................................................ 399
46.8 Recognizing Pan and Dragging Gestures .......................................................................... 400
46.9 Recognizing Swipe Gestures ............................................................................................. 400
46.10 Recognizing Long Touch (Touch and Hold) Gestures ..................................................... 401
46.11 Summary ........................................................................................................................ 401
47. An iOS 7 Gesture Recognition Tutorial .............................................................................. 403
47.1 Creating the Gesture Recognition Project ........................................................................ 403
47.2 Designing the User Interface ............................................................................................ 403
47.3 Implementing the Action Methods .................................................................................. 406
xviii
47.4 Testing the Gesture Recognition Application ................................................................... 407
48. An Overview of iOS 7 Collection View and Flow Layout .................................................... 409
48.1 An Overview of Collection Views...................................................................................... 409
48.2 The UICollectionView Class .............................................................................................. 412
48.3 The UICollectionViewCell Class ........................................................................................ 412
48.4 The UICollectionReusableView Class ................................................................................ 413
48.5 The UICollectionViewFlowLayout Class ............................................................................ 413
48.6 The UICollectionViewLayoutAttributes Class ................................................................... 414
48.7 The UICollectionViewDataSource Protocol ...................................................................... 414
48.8 The UICollectionViewDelegate Protocol .......................................................................... 415
48.9 The UICollectionViewDelegateFlowLayout Protocol ........................................................ 416
48.10 Cell and View Reuse ....................................................................................................... 417
48.11 Summary ........................................................................................................................ 419
49. An iOS 7 Storyboard-based Collection View Tutorial ......................................................... 421
49.1 Creating the Collection View Example Project ................................................................. 421
49.2 Removing the Template View Controller ......................................................................... 421
49.3 Adding a Collection View Controller to the Storyboard ................................................... 422
49.4 Adding the Collection View Cell Class to the Project ........................................................ 424
49.5 Designing the Cell Prototype ............................................................................................ 424
49.6 Implementing the Data Model ......................................................................................... 426
49.7 Implementing the Data Source ........................................................................................ 428
49.8 Testing the Application ..................................................................................................... 430
49.9 Setting Sizes for Cell Items ............................................................................................... 431
49.10 Changing Scroll Direction ............................................................................................... 433
49.11 Implementing a Supplementary View ............................................................................ 435
49.12 Implementing the Supplementary View Protocol Methods ........................................... 438
49.13 Deleting Collection View Items ...................................................................................... 439
49.14 Summary ........................................................................................................................ 440
50. Subclassing and Extending the iOS 7 Collection View Flow Layout .................................... 441
50.1 About the Example Layout Class ...................................................................................... 441
50.2 Subclassing the UICollectionViewFlowLayout Class ......................................................... 442
50.3 Extending the New Layout Class ...................................................................................... 442
50.4 Implementing the layoutAttributesForItemAtIndexPath: Method .................................. 443
50.5 Implementing the layoutAttributesForElementsInRect: Method .................................... 444
50.6 Implementing the modifyLayoutAttributes: Method ....................................................... 445
50.7 Adding the New Layout and Pinch Gesture Recognizer ................................................... 446
xix
50.8 Implementing the Pinch Recognizer ................................................................................. 447
50.9 Avoiding Image Clipping ................................................................................................... 450
50.10 Testing the Application ................................................................................................... 450
50.11 Summary ........................................................................................................................ 451
51. Drawing iOS 7 2D Graphics with Core Graphics ................................................................. 453
51.1 Introducing Core Graphics and Quartz 2D........................................................................ 453
51.2 The drawRect Method ...................................................................................................... 453
51.3 Points, Coordinates and Pixels ......................................................................................... 454
51.4 The Graphics Context ....................................................................................................... 454
51.5 Working with Colors in Quartz 2D .................................................................................... 455
51.6 Summary .......................................................................................................................... 456
52. An iOS 7 Graphics Tutorial using Core Graphics and Core Image ....................................... 457
52.1 The iOS Drawing Example Application ............................................................................. 457
52.2 Creating the New Project ................................................................................................. 457
52.3 Creating the UIView Subclass ........................................................................................... 457
52.4 Locating the drawRect Method in the UIView Subclass ................................................... 458
52.5 Drawing a Line .................................................................................................................. 459
52.6 Drawing Paths .................................................................................................................. 462
52.7 Drawing a Rectangle ......................................................................................................... 463
52.8 Drawing an Ellipse or Circle .............................................................................................. 464
52.9 Filling a Path with a Color ................................................................................................. 465
52.10 Drawing an Arc ............................................................................................................... 467
52.11 Drawing a Cubic Bézier Curve ......................................................................................... 468
52.12 Drawing a Quadratic Bézier Curve .................................................................................. 469
52.13 Dashed Line Drawing ...................................................................................................... 470
52.14 Drawing Shadows ........................................................................................................... 472
52.15 Drawing Gradients .......................................................................................................... 473
52.16 Drawing an Image into a Graphics Context .................................................................... 478
52.17 Image Filtering with the Core Image Framework ........................................................... 480
52.18 Summary ........................................................................................................................ 482
53. Basic iOS 7 Animation using Core Animation..................................................................... 483
53.1 UIView Core Animation Blocks ......................................................................................... 483
53.2 Understanding Animation Curves .................................................................................... 484
53.3 Receiving Notification of Animation Completion ............................................................. 485
53.4 Performing Affine Transformations.................................................................................. 485
53.5 Combining Transformations ............................................................................................. 486
xx
53.6 Creating the Animation Example Application .................................................................. 486
53.7 Implementing the Interface File ....................................................................................... 486
53.8 Drawing in the UIView ...................................................................................................... 487
53.9 Detecting Screen Touches and Performing the Animation .............................................. 487
53.10 Building and Running the Animation Application .......................................................... 489
53.11 Summary ........................................................................................................................ 490
54. iOS 7 UIKit Dynamics – An Overview ................................................................................. 491
54.1 Understanding UIKit Dynamics ......................................................................................... 491
54.2 The UIKit Dynamics Architecture...................................................................................... 492
54.2.1 Dynamic Items .......................................................................................................... 492
54.2.2 Dynamic Behaviors .................................................................................................... 492
54.2.3 The Reference View ................................................................................................... 493
54.2.4 The Dynamic Animator ............................................................................................. 493
54.3 Implementing UIKit Dynamics in an iOS 7 Application ..................................................... 494
54.4 Dynamic Animator Initialization ....................................................................................... 494
54.5 Configuring Gravity Behavior ........................................................................................... 495
54.6 Configuring Collision Behavior ......................................................................................... 496
54.7 Configuring Attachment Behavior .................................................................................... 498
54.8 Configuring Snap Behavior ............................................................................................... 500
54.9 Configuring Push Behavior ............................................................................................... 500
54.10 The UIDynamicItemBehavior Class ................................................................................. 502
54.11 Combining Behaviors to Create a Custom Behavior....................................................... 503
54.12 Summary ........................................................................................................................ 504
55. An iOS 7 UIKit Dynamics Tutorial ...................................................................................... 505
55.1 Creating the UIKit Dynamics Example Project .................................................................. 505
55.2 Adding the Dynamic Items ............................................................................................... 505
55.3 Creating the Dynamic Animator Instance ........................................................................ 507
55.4 Adding Gravity to the Views ............................................................................................. 508
55.5 Implementing Collision Behavior ..................................................................................... 509
55.6 Attaching a View to an Anchor Point................................................................................ 511
55.7 Implementing a Spring Attachment Between two Views ................................................ 514
55.8 Summary .......................................................................................................................... 515
56. An Introduction to iOS 7 Sprite Kit Programming .............................................................. 517
56.1 What is Sprite Kit? ............................................................................................................ 517
56.2 The Key Components of a Sprite Kit Game ...................................................................... 518
56.2.1 Sprite Kit View ........................................................................................................... 518
剩余878页未读,继续阅读
108 浏览量
2018-05-15 上传
2018-12-14 上传
2019-11-15 上传
2017-09-26 上传
2017-09-26 上传
2015-06-11 上传
2023-03-16 上传
网事随风79
- 粉丝: 3
- 资源: 9
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
最新资源
- 毕业设计&课设-仿真工具箱(MATLAB).zip
- flutter.widgets
- Greentask-crx插件
- Wrappit:用于在PacketWrapper中生成数据包类的程序
- matlab求导代码-rsHRF:从BOLD-fMRI信号估计静止状态HRF
- FakeSunCompany-Website
- 基于halcon的旋转中心仿真测试.rar
- NeoClient:Neo4j的轻量级OGM,支持事务和BOLT协议
- 毕业设计&课设-根据系统要求配置FMCW波形。然后定义目标的范围和速度,并模拟其位移….zip
- PythonKit:与 Python 交互的 Swift 框架
- react-weather-app:SheCodes React最终项目
- Divi Builder guide-crx插件
- 小游戏-天天消消乐(附带源码)
- junior-programming:我的初中生及其项目的资料库
- gateway-nacos-sleuth.7z
- design-pattern:Java设计模式,和简书的https
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功