The object is a collection of as an array or set of Cocoa classes that may include the collection classes. This collection of classes adopts the NSFastEnumeration protocol. This protocol can be used to retrieve elements that are held by an instance by using a syntax that is similar to a standard C for loop.

Look at this instance:
NSArray *anArray = // get an array;
for (id element in anArray)
{
   /* code that acts on the element */
}

Suggest An Answer

No suggestions avaliable!