0%

Book Description

This excerpt addresses memory management. It describes the memory management model and object reference types. It also discusses best practices for design patterns that impact memory consumption, namely singleton and dependency injection.

Table of Contents

  1. Memory management
    1. Memory Consumption
      1. Stack Size
      2. Heap Size
    2. Memory Management Model
    3. Autoreleasing Objects
    4. Autorelease Pool Blocks
    5. Automatic Reference Counting
      1. Rules of ARC
    6. Reference Types
      1. Variable Qualifiers
      2. Property Qualifiers
    7. Getting Your Hands Dirty
      1. Photo Model
      2. Storyboard Update
      3. Method Implementations
      4. Output Analysis
    8. Zombies
    9. Rules of Memory Management
    10. Retain Cycles
      1. Rules to Avoid Retain Cycles
      2. Common Scenarios for Retain Cycles
      3. Observers
      4. Returning Errors
    11. Weak Type: id
      1. Solution to the Problem
    12. Object Longevity and Leaks
    13. Singletons
    14. Finding Mystery Retains
    15. Best Practices
    16. Memory Usage in Production
    17. Summary