• Online, Self-Paced
Course Description

Defensive programming in iOS has to do with using coding practices and techniques to create apps that are reliable, predictable, and resilient. This course will teach you about methods and best practices for interacting safely and easily with the Internet from within an iOS app.

Learning Objectives

Managing TCP Connections

  • start the course
  • create a TCP client connection from an iOS app
  • send and receive data over a TCP connection in an iOS app

Testing Network Availability

  • determine when an iOS app can and cannot access the Internet
  • determine when an iOS app can and cannot reach a specific IP address
  • determine when an iOS app can and cannot access the Internet
  • install and configure the network link conditioner to be able to test iOS apps in different connection conditions

Working with URLs

  • use CF functions to encode URLs
  • use CF functions to decode URLs

Network Interaction Using NSURLConnection

  • use NSURLConnection to make synchronous and asynchronous network calls
  • use NSURLConnection to make asynchronous network calls without using custom delegates

Network Interaction Using NSURLSession

  • create and apply a configuration object to an NSURLSession instance
  • request a URL in a simple manner using NSURLSession and system delegates
  • request a URL in a flexible manner using NSURLSession and custom delegates
  • stop script execution in any HTML loaded into a WebView
  • disallow Internet traffic over cellular connections in an iOS app
  • capture and handle redirect responses from a server

Managing Upload and Download Operations

  • use NSURLSession to reliably download and save files in an iOS app
  • use NSURLSession to handle users stopping and starting download operations
  • use NSURLSession to handle downloads that fail
  • use NSURLSession to upload files to a web server

Practice: iOS Networking

  • use common techniques for managing network interaction

Framework Connections