title: UICollectionView delegate method cellForItemAtIndexPath:indexPath not called from sizeForItemAtIndexPath
body: <p>When I call </p>
  
  <pre><code>[collectionView cellForItemAtIndexPath:indexPath:]
  </code></pre>
  
  <p>from inside </p>
  
  <pre><code>[collectionView:layout:sizeForItemAtIndexPath:]
  </code></pre>
  
  <p>then the delegate method is not triggered. Any idea why not?</p>
  
  <p>You can see it <a href="http://www.youtube.com/watch?v=6YtCp-d8ERQ&amp;feature=youtu.be" rel="nofollow noreferrer">here</a>.</p>
  
  <pre><code>- (UICollectionViewCell *)collectionView:(UICollectionView *)collectionView cellForItemAtIndexPath:(NSIndexPath *)indexPath {
  
      CustomCell *cell = [self.collectionView dequeueReusableCellWithReuseIdentifier:@"CustomCell" forIndexPath:indexPath];
  
      [cell configureWithData:self.data[indexPath.row]];
  
      return cell;
  }
  
  
  - (CGSize)collectionView:(UICollectionView *)collectionView layout:(UICollectionViewLayout*)collectionViewLayout sizeForItemAtIndexPath:(NSIndexPath *)indexPath {
  
      CustomCell * cell = (CustomCell *)[collectionView cellForItemAtIndexPath:indexPath];
  
      return [cell preferredSize];
  }
  </code></pre>
  
  <p>What I want to do is to ask the cell for its preferred size.</p>
  
  <p>I could do</p>
  
  <pre><code>CustomCell * cell = (CustomCell *)[self collectionView:collectionView cellForItemAtIndexPath:indexPath];
  </code></pre>
  
  <p>but then a never-ending loop cycle is triggered</p>
  
  <p>why is its delegate method not called as it should be?</p>