ビューコントローラーを使用してウィンドウを作成しようとしています (.Net の GroupBox のようなものだと思います (間違っている場合は修正してください..))。シミュレーターでアプリケーションを起動しようとすると、例外がスローされました。ストーリーボードを使用しています。
私のコードは次のとおりです。
//
// ViewController.m
// 100FMPlayer
//
// Created by Guy Kaplan on 7/14/13.
// Copyright (c) 2013 Guy Kaplan. All rights reserved.
//
#import "Song.h"
#import "ViewController.h"
@interface ViewController ()
@end
@implementation ViewController
-(id)init
{
self = [super init];
self.arSongsCollection = [[NSMutableArray alloc] init];
_tableView.delegate = self;
_tableView.dataSource = self.arSongsCollection;
return self;
}
- (void)viewDidLoad
{
[super viewDidLoad];
// Do any additional setup after loading the view, typically from a nib.
[_arSongsCollection addObject:[[Song alloc] initWithTitle:@"Song" andArtist:@"Artist" andURL:[NSURL URLWithString:@"http://songurl.com/song.mp3"]]];
}
@end