万本电子书0元读

万本电子书0元读

顶部广告

Objective-C Memory Management Essentials电子书

售       价:¥

5人正在读 | 0人评论 9.8

作       者:Gibson Tang

出  版  社:Packt Publishing

出版时间:2015-03-25

字       数:53.3万

所属分类: 进口书 > 外文原版书 > 电脑/网络

温馨提示:数字商品不支持退换货,不提供源文件,不支持导出打印

为你推荐

  • 读书简介
  • 目录
  • 累计评论(0条)
  • 读书简介
  • 目录
  • 累计评论(0条)
If you are new to Objective-C or a veteran in iOS application development, this is the book for you. This book will ensure that you can actively learn the methods and concepts in relation to memory management in a more engaging way. Basic knowledge of iOS development is required for this book.
目录展开

Objective-C Memory Management Essentials

Table of Contents

Objective-C Memory Management Essentials

Credits

About the Authors

About the Reviewers

www.PacktPub.com

Support files, eBooks, discount offers, and more

Why subscribe?

Free access for Packt account holders

Preface

What this book covers

What you need for this book

Who this book is for

Conventions

Reader feedback

Customer support

Downloading the example code

Errata

Piracy

Questions

1. Introduction to Objective-C Memory Management

Why do we need memory management in Objective-C?

An object's ownership and life cycle

Ownership of object and reference counting

What's a memory leak and why pay attention to it?

What is an object within Objective-C?

Summary

2. Automatic Reference Counting

What is ARC and how does it work?

How ARC looks

Project settings for ARC

A memory model in Objective-C

What you need to know about ARC and weak references

Summary

3. Using Autorelease Pools

Understanding the autorelease pool mechanism

Autorelease pool mechanism

Reducing peak memory footprint with autorelease pool blocks

An overview of Apple autoreleased classes

NSRunLoop

NSException

ARC and autorelease

Autorelease pool blocks and threads

Summary

4. Object Creation and Storage

Creation and initialization of objects

What is a class?

Classes

Object immutability

Object mutability

Inheritance

Convenience initializers

An Objective-C programmer's responsibility

The singleton pattern

Creating @property

Creating custom methods

String formatting

Summary

5. Managing Your Application Data

Device memory

Image optimization

Lazy loading

Control creation

Caching

SDWebImage

Object serialization

SQLite

SQLite versus Core Data

Summary

6. Using Core Data for Persistence

Why use Core Data?

Understanding Core Data concepts

Putting it into practice

Getting into the code

Saving data into the persistent store

Deleting data from the persistent store

Updating data

Summary

7. Key-value Programming Approaches

What is key-value coding or KVC?

The NSKeyValueCoding protocol

Compliance of attributes and one-to-one relationships

Compliance of indexed one-to-many relationships

Compliance of unordered many-to-many relationships

Advantages of key-value coding

Disadvantages of key-value coding

Manual subsets of NSKeyValueCoding behavior

Advantages of creating your own lookup path

Disadvantages of creating your own lookup path

Associated objects

Advantages of using associated objects

Disadvantages of using associated objects

Selectors as keys

Advantages of using selectors as keys

Disadvantages of using selectors as keys

Maximum flexibility and handling unusual keys/values

Advantages of doing your own implementation

Disadvantages of doing your own implementation

Key-value observing

Implementing key-value observing

Performance considerations

Summary

8. Introduction to Swift

Welcome to Swift

Basics of Swift

Variable declaration

Iterating statements

Conditional statements

Functions

Classes and structures in Swift

Closures

Memory management in Swift

Summary

9. Memory Management and Debugging

Memory leaks

Strong/weak references

Retain cycles

Memory overuse

Using the debugger and breakpoints

Collecting data on your app

Plumbing memory leaks

Using the LLVM / Clang Static Analyzer

Using NSZombie

Summary

10. Tips and Tricks for Memory Management

Objective-C, C, and memory management

Getters and setters

The property attribute in Objective-C

Performance guidelines

Don't overthink about memory management

When to avoid KVC and KVO

Summary

11. Features of Xcode 6

Introducing Xcode 6

What's new in storyboard

Allowing storyboard or the NIB file to replace launch images

Launching images from your app

Universal storyboards

Debugging in Xcode 6

Debug gauges

What's new in Interface Builder

Playground for Swift

Summary

Index

累计评论(0条) 0个书友正在讨论这本书 发表评论

发表评论

发表评论,分享你的想法吧!

买过这本书的人还买过

读了这本书的人还在读

回顶部