Free Sample
+ Collection

iPhone Applications Tune-Up

Starting
Loyal Moses

High performance tuning guide for real-world iOS projects
$26.99
$44.99
RRP $26.99
RRP $44.99
eBook
Print + eBook

Want this title & more?

$16.99 p/month

Subscribe to PacktLib

Enjoy full and instant access to over 2000 books and videos – you’ll find everything you need to stay ahead of the curve and make sure you can always get the job done.

Book Details

ISBN 139781849690348
Paperback256 pages

About This Book

  • Tune up every aspect of your iOS application for greater levels of stability and performance
  • Improve the users' experience by boosting the performance of your app
  • Learn to use Xcode's powerful native features to increase productivity
  • Profile and measure every operation of your application for performance
  • Integrate powerful unit-testing directly into your development workflow
  • Learn everything from architecture and syntax to memory, network, and animation performance

Who This Book Is For

This book is for iOS application developers who are interested in resolving application performance bottlenecks in both new and existing Xcode projects. Readers should be familiar with the basic concepts and principles of iOS development, Objective-C syntax, and use of Apple's Xcode development environment.

Table of Contents

Chapter 1: Performance, Bottlenecks, and Fundamentals
Success and performance
Perception of performance
Performance fundamentals
Approaching performance
Process management
Memory
Storage
Network
User interface
Be a good neighbor
Application design and architecture
Application performance
Summary
Chapter 2: Design for Performance
Preparing the project
Project organization
Project structure
Groups and files
Code structure
Summary
Chapter 3: Maintainability
Variable naming conventions
Method naming conventions
Camel case
Syntax efficiency
Readability versus compactness
Dot syntax
Re-factoring
Library bloat
LIPO
Comments
Documentation
Summary
Chapter 4: Reliability
Exception handling
Error checking
Unit testing
Preparing a project for logic unit testing
Preparing a project for application unit testing
Summary
Chapter 5: Performance Measurement and Benchmarking
Static analyzer
Instruments
Summary
Chapter 6: Syntax and Process Performance
Iteration loops
Object reuse
Bitmasks
Sorting
Bubble sort
Selection sort
Bucket sort
Quicksort
Run loops
Timers
Semaphores
Summary
Chapter 7: Network Performance
Sockets
Streams
Protocols
Bandwidth
Compression
Façade pattern
Summary
Chapter 8: Memory Performance
Garbage collection
Alloc
Dealloc
Copy
Retain
Release
Autorelease
didReceiveMemoryWarning
Summary
Chapter 9: Application and Object Lifecycles
Mise en place
Application lifecycle
Application startup sequence
Application execution
Application termination sequence
Application init
awakeFromNib
application: didFinishLaunchingWithOptions
applicationDidBecomeActive
applicationWillEnterForeground
applicationWillResignActive
applicationDidEnterBackground
applicationWillTerminate
Object lifecycle
Object init
Summary
Chapter 10: Animation, View, and Display Performance
View performance
Animated content
Core Animation
Item renderers
Summary
Chapter 11: Database and Storage Performance
Disk
Cache
Compression
SQLite
Core Data
Summary
Chapter 12: Common Cocoa Design Patterns
Why design patterns are critical
Singleton
Mediator
Delegate
Adaptor
Decorator
Model-View-Controller
Summary
Chapter 13: The Xcode Advantage
Distributed builds
Dead code stripping
Compiler
Debugger
Source code management
Summary

What You Will Learn

  • Understand the basic principles of application performance and bottlenecks
  • Learn the benefits and techniques of performance-driven development
  • Analyze an application with proper benchmarking and measurement utilities
  • Identify iOS and device capabilities and limitations
  • Improve network and communications performance
  • Understand the common pitfalls caused by misuse of basic language syntax
  • Learn design patterns that can increase application simplicity and performance
  • Become more familiar with the object and component lifecycle
  • Use unit testing and exception handling to create better code
  • Store and recall data faster and more efficiently

In Detail

The best iPhone applications are the ones that demonstrate smooth, fast, efficient and optimal performance. An application should be designed to run at 200 mph, but operate just as smoothly as it would at 5 mph. Developing an application that supports such a wide range of performance needs is no small task and requires an understanding of the basic elements of performance as well as a strong strategy.

This book covers every aspect of tuning, optimizing, and squeezing every last bit of performance out of an iOS project. From application architecture and design to development and deployment, readers will be guided through the entire process of tuning an iOS application for high performance.

Every line of code presents an opportunity to improve upon the effective performance of an application. This book begins with the fundamentals of performance, demonstrating the impact poor performance can have on the success of an application. Apple's App Store is riddled with applications that fall just short of success and it isn't too much of a stretch to attribute many of these failures to a lack of optimization. Readers will be lead through each chapter, learning every aspect of performance tuning from simple syntax tips and tricks to advanced process management, and network and memory optimizations.

In addition to theories, syntax, and detailed code examples, readers will learn to take advantage of Apple's powerful performance measurement and benchmarking utilities to identify the specific components of an iOS project that might need attention.

Authors

Read More