Tab Bar Item Instantiation

#1

How come when we instantiated the tab bar item for the reminder view controller we used this method:

  • (instancetype)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil
    {
    self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil];

    if (self) {

      [b]UITabBarItem *tbi = self.tabBarItem[/b];
      
      tbi.title = @"Reminder";
      
      UIImage *i = [UIImage imageNamed:@"Time.png"];
      tbi.image = i;
    

    }

    return self;
    }

but in the hypnosis view controller we only accessed the tab bar item through the property by using:

-(instancetype)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil
{
self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil];

if (self) {
    
    [b]self.tabBarItem.title[/b] = @"Hypnotize";
    
    UIImage *i = [UIImage imageNamed:@"Hypno.png"];
    
    self.tabBarItem.image = i;
}

return self;

}