O'Reilly logo

Mastering iOS 11 Programming - Second Edition by Donny Wals

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Extracting the bounce animation

The process of extracting our bounce animation is a little more complex than the process of extracting the contacts. The purpose of extracting this bounce animation is to make it bounce so that we can make other objects in other sections of our app bounce just as the contact cell's image does.

To figure out what our bounce animation helper should do exactly and how it should work, it's a great idea to think about how you want to use this helper at the call site. The call site is defined as the place where you plan to use your helper. So, in this case, the call site is considered the ViewController. Let's write some pseudo code to try and determine what we will program later:

let onBounceComplete = { [weak self] ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required