Using the UIImageView+MKNetworkKitAdditions.h category and caching the images

In this recipe we will expand on the ITunesEngine header file created in the Creating and using the MKNetworkKit engine recipe of this chapter by adjusting the caching settings of MKNetworkEngine. We will also use the UIImageView+MKNetworkKitAdditions category to download images and display them once the download is complete.

This recipe will introduce two concepts: the MKNetworkKit caching capability and using the categories that come with MKNetworkKit. We will also get a better understanding of why we subclass MKNetworkEngine.

Getting ready

This recipe is compatible with both iOS and OS X. We will need to download the framework from https://github.com/MugunthKumar/MKNetworkKit ...

Get iOS and OS X Network Programming Cookbook now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.