• Online, Self-Paced
Course Description

Defensive Programming in iOS has to do with using coding practices and techniques to create apps, that are reliable and resilient. In this course, you will learn about thinking defensively when creating functions and methods, and also when working with inputs to your programs.

Learning Objectives

Working with iOS App Input

  • start the course
  • create code that handles file inputs to an iOS app
  • create code that handles url scheme inputs to an iOS app
  • validate user-provided input using Objective-C
  • use a real-time approach to validating user-provided input in Objective-C
  • use secure coding principles to guard against format string attacks
  • restrict free navigation around the Web based on user input in a UIWebView

Functions and Methods

  • use best practices to name functions and methods in Objective-C
  • use best practices to name accessor methods in Objective-C
  • use best practices to name delegate methods in Objective-C
  • reduce method complexity in iOS apps using Objective-C
  • overload a function to reduce code complexity in Swift
  • design functions that have a single and defined focus
  • identify and use different class naming standards in Objective-C

Constants and Defaults

  • create and use constants in Objective-C
  • create and use constants in Swift
  • create and use resource files in an iOS app
  • easily store and retrieve data from the defaults database

Conditionals

  • recognize how using brackets can protect against potential bugs
  • design while loops that are not vulnerable to running forever
  • design for loops that are not vulnerable to running forever
  • identify and avoid bugs caused by altered loop variables

Practice: Handling Inputs and Validation

  • handle various types of inputs to an iOS app

Framework Connections