title: Accessing properties of objects in an NSSet
body: <p>I have an object called Contact. A Contact has a relationship with a set of PhoneNumber objects.</p>
  
  <p>A phone number has a label and a value property (both NSString pointers).</p>
  
  <p>How do I get a set of all the phone number labels for a given Contact?</p>
  
  <p>Here is the code for what I want to do, but I think there must be an easier way:</p>
  
  <pre><code>NSSet *phoneNumbersSet = contact.phoneNumbers;
  NSArray *phoneNumbersArray = [phoneNumbersSet allObjects];
  NSMutableSet *phoneNumberLabelSet = [NSMutableSet setWithCapacity:0];
  for (PhoneNumber* phoneNumber in phoneNumbersArray) {
     [phoneNumberLabelSet addObject:phoneNumber.label];
  }
  </code></pre>