没有合适的资源?快使用搜索试试~ 我知道了~
温馨提示
In this book, we’ll be talking about Cocoa and Cocoa Touch, the frameworks used on OS X and iOS, respectively. Along the way, we’ll also be covering Swift, including its syntax and features.
资源推荐
资源详情
资源评论
MACINTOSHIPAD & IPHONE
Swift Development with Cocoa
ISBN: 978-1-491-90894-5
US $39.99 CAN $41.99
Twitter: @oreillymedia
facebook.com/oreilly
Ready to build apps for iPhone, iPad, and Mac now that Swift has landed? If
you’re an experienced programmer who’s never touched Apple developer
tools, this hands-on book shows you how to use the Swift language to
make incredible iOS and OS X apps, using Cocoa and Cocoa Touch.
Learn how to use Swift in a wide range of real-world situations, with
Cocoa features such as EventKit and Core Animation. You’ll pick up Swift
language features and syntax along the way, and understand why using
Swift (instead of Objective-C) makes iOS and Mac app development easier,
faster, and safer. You’ll also work with several exercises to help you practice
as you learn.
■ Learn the OS X and iOS application lifecycle
■ Use storyboards to design adaptive interfaces
■ Explore graphics systems, including the built-in 2D and 3D
game frameworks
■ Display video and audio with AVFoundation
■ Store data locally with the lesystem, or on the network with
iCloud
■ Display lists or collections of data with table views and
collection views
■ Build apps that let users create, edit, and work with documents
■ Use MapKit, Core Location, and Core Motion to interact with
the world
Jonathon Manning, cofounder of Secret Lab, is a mobile software engineer,
game designer, and computing researcher. Follow him on Twitter at @desplesda.
Paris Butteld-Addison, also a cofounder of Secret Lab, is a mobile software engineer,
game designer, and computing researcher. Follow him on Twitter at @parisba.
Tim Nugent, not a cofounder of Secret Lab, is a mobile app developer, game
designer, PhD student, and author. Follow him on Twitter at @The_McJones.
www.allitebooks.com
Swift Development with Cocoa
by Jonathon Manning, Paris Buttfield-Addison, and Tim Nugent
Copyright © 2015 Secret Lab. All rights reserved.
Printed in the United States of America.
Published by O’Reilly Media, Inc., 1005 Gravenstein Highway North, Sebastopol, CA 95472.
O’Reilly books may be purchased for educational, business, or sales promotional use. Online editions are
also available for most titles (http://safaribooksonline.com). For more information, contact our corporate/
institutional sales department: 800-998-9938 or corporate@oreilly.com.
Editor: Rachel Roumeliotis
Production Editor: Matthew Hacker
Copyeditor: Jasmine Kwityn
Proofreader: Charles Roumeliotis
Indexer: Wendy Catalano
Cover Designer: Ellie Volckhausen
Interior Designer: David Futato
Illustrator: Rebecca Demarest
December 2014: First Edition
Revision History for the First Edition:
2014-12-08: First release
See http://oreilly.com/catalog/errata.csp?isbn=9781491908945 for release details.
The O’Reilly logo is a registered trademark of O’Reilly Media, Inc. Swift Development with Cocoa, the cover
image of an Australasian gannet, and related trade dress are trademarks of O’Reilly Media, Inc.
Many of the designations used by manufacturers and sellers to distinguish their products are claimed as
trademarks. Where those designations appear in this book, and O’Reilly Media, Inc. was aware of a trademark
claim, the designations have been printed in caps or initial caps.
While the publisher and the authors have used good faith efforts to ensure that the information and in‐
structions contained in this work are accurate, the publisher and the authors disclaim all responsibility for
errors or omissions, including without limitation responsibility for damages resulting from the use of or
reliance on this work. Use of the information and instructions contained in this work is at your own risk. If
any code samples or other technology this work contains or describes is subject to open source licenses or
the intellectual property rights of others, it is your responsibility to ensure that your use thereof complies
with such licenses and/or rights.
ISBN: 978-1-491-90894-5
[M]
www.allitebooks.com
Table of Contents
Preface. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xi
1. Cocoa Development Tools. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
The Mac and iOS Developer Programs 1
Registering for a Developer Program 2
Downloading Xcode 3
Creating Your First Project with Xcode 4
The Xcode Interface 7
Developing a Simple Swift Application 13
Designing the Interface 13
Connecting the Code 15
Using the iOS Simulator 17
Testing iOS Apps with TestFlight 19
2. Programming with Swift. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
The Swift Programming Language 21
Playgrounds 23
Variables and Constants 24
Types 26
Tuples 28
Arrays 28
Dictionaries 29
Control Flow 30
Switches 33
Functions and Closures 35
Using Functions as Variables 37
Closures 39
Objects 40
Inheritance 42
iii
www.allitebooks.com
剩余471页未读,继续阅读
资源评论
iMand
- 粉丝: 3
- 资源: 12
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
最新资源
- 多微网优化模型matlab 采用粒子群算法分析两个微网的优化调度,得到蓄电池,发电机以及微网间功率传输,程序有参考资料
- 潮流计算程序matlab 牛拉法 采用matlab对9节点进行潮流计算,采用牛拉法,程序运行可靠
- 微网优化调度matlab 采用matlab+yalmip编制含分布式和储能的微网优化模型,程序采用15分钟为采集节点,利用cplex求解,程序考虑发电机的启停约束,程序运行可靠
- PMSM永磁同步电机仿真三电平SVPWM矢量控制matlab PMSM双环矢量控制传统三电平
- 路径规划人工势场法以及改进人工势场法matlab代码,包含了
- MobaXterm 是一款功能强大且实用的终端仿真器软件.docx
- 三菱FX3U底层源码,PLSR源码 总体功能和指令可能支持在RUN中下载程序,支持注释的写入和读取,支持脉冲输出与定位指令(包括PLSY PWM PLSR PLSV DRVI DRVA 等指令
- Oracle Database Gateways for Win32-11gR2
- python071基于RSA加密算法软件的研究设计
- 成熟量产低压无刷伺服驱动 方案 全套软硬件资料 源码 原理图 需要的直接拿 基于28035平台
- 欧姆龙PLC ST语言6轴伺服RS232C通讯板CP1W-C IF0 真实项目程序,ST语言写的FB块 PLC用是两台CP1H-X40DT-D配置4块RS232C通讯板CP1W-CIF01 触摸屏是N
- 欧姆龙CP1H与力士乐VFC-x610变频器通讯程序功能:原创程序,可直接用于现场程序 欧姆龙CP1H的CIF11通讯板,实现对力士乐VFC-x610变频器 设定频率,控制正反转,读取实际频率,读取
- 级联型电力电子变压器,高压直流MMC控制系统,级联数可选,调 制方式有移相载波,nlm及混合调制,拥有冒泡排序,递归排序等方法,可控制三相不平衡与环流
- 西门子PLC双轴定位算法电池焊接控制程序-S7-1200 +威纶通触摸屏 S7-1200PLC做的电池焊接程序,电池包里面有n*m行列个电池 程序设计灵活SCL语言+梯形图,采用了位置试教与定位路径规
- 变压器副边突然短路simulink仿真
- MATLAB代码:基于模型预测控制的楼宇负荷需求响应研究 关键词:楼宇负荷 空调 模型预测控制 需求响应 仿真平台:MATLAB+CVX平台 主要内容:代码主要做的是一个建筑楼宇的需求响应问题,首
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功