Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.
Block-based Cocoa Methods
With iOS 4 and the introduction of blocks, many of the built-in Cocoa framework methods have block-based equivalents. Covering every single block-based method is impossible in a single chapter and demands a complete book of its own. But Apple follows a pattern. In this section, I briefly explain some of the methods that take block parameters and give some hints and tips on when to look out for a block-based equivalent method in the framework.
UIView Animations using Blocks
Prior to iOS 4, view-based animations were usually done using UIView’s class methods, beginAnimations and commitAnimations. You write the code you want to be animated within these two statements and the animation is performed after the call to commitAnimations.