title: Print NSMutableArray into UITableView
body: <p>In my application I have a tableview with a barbuttonitem. When I press the barbuttonitem, I see an alertcontroller that allows me to enter data. Then later, save these data within a NSMutableArray and my purpose is to print one of these data within the cells of a tableview. The problem is that the data acquisition is correct, but the tableview remains empty. I do not understand why, it seems all right!</p>
  
  <p>Class: FeedInfo</p>
  
  <pre><code>#import &lt;Foundation/Foundation.h&gt;
  
  @interface FeedInfo : NSObject
  @property (nonatomic,strong) NSString *feedURL;
  @property (nonatomic,strong) NSString *feedTitle;
  @property (nonatomic,strong) NSString *feedCategory;
  @end
  </code></pre>
  
  <p>And then I have a barbuttonitem inside a tableview. When I click on this button, I open a controller alert that allows me to enter 3 fields: url, feed, category.</p>
  
  <p>I have declared <code>@property(nonatomic,strong) NSMutableArray *feedArray;</code></p>
  
  <p>I then insert these dates into the NSMutableArray.</p>
  
  <pre><code>- (IBAction)inserFeed:(UIBarButtonItem *)sender {
      UIAlertController * alertController = [UIAlertController alertControllerWithTitle: @"Feed RSS: info?"
                                                                                message: @""
                                                                         preferredStyle:UIAlertControllerStyleAlert];
  
      [alertController addTextFieldWithConfigurationHandler:^(UITextField *textField) {
          textField.placeholder = @"Feed URL";
          textField.clearButtonMode = UITextFieldViewModeWhileEditing;
          textField.borderStyle = UITextBorderStyleRoundedRect;
      }];
  
      [alertController addTextFieldWithConfigurationHandler:^(UITextField *textField) {
          textField.placeholder = @"Feed Title";
          textField.clearButtonMode = UITextFieldViewModeWhileEditing;
          textField.borderStyle = UITextBorderStyleRoundedRect;
      }];
  
      [alertController addTextFieldWithConfigurationHandler:^(UITextField *textField) {
          textField.placeholder = @"Feed category";
          textField.clearButtonMode = UITextFieldViewModeWhileEditing;
          textField.borderStyle = UITextBorderStyleRoundedRect;
  
      }];
  
      [alertController addAction:[UIAlertAction actionWithTitle:@"OK" style:UIAlertActionStyleDefault handler:^(UIAlertAction *action) {
  
          NSArray * textfields = alertController.textFields;
  
          UITextField * urlfield = textfields[0];
          UITextField * titlefield = textfields[1];
          UITextField * categoryfield = textfields[2];
  
          FeedInfo *newFeed = [[FeedInfo alloc] init];
          newFeed.feedURL = urlfield.text;
          newFeed.feedTitle = titlefield.text;
          newFeed.feedCategory = categoryfield.text;
  
  
          [self.feedArray addObject:newFeed];
          [self.tableView reloadData];
      }]];
  
      [self presentViewController:alertController animated:YES completion:nil];
  }
  </code></pre>
  
  <p>Everything works here. The problem is printing one of these fields within a cell of my tableview.</p>
  
  <pre><code>-(UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
      UITableViewCell *cell = [self.tableView dequeueReusableCellWithIdentifier:@"cell"];
      FeedInfo *feedToShow = [self.feedArray objectAtIndex:indexPath.row];
      cell.textLabel.text = feedToShow.feedTitle;
      return cell;
  }
  </code></pre>