メソッドが実行されるときのクラスで、私はこれを入れました:
[[NSNotificationCenter defaultCenter] postNotificationName:@"locationFromZipFound" object:array];
通知を受け取りたいクラスには、次のものがあります。
[[NSNotificationCenter defaultCenter] addObserver:self
selector:@selector(getZipLocation:)
name:@"locationFromZipFound"
object:nil];
問題は、これが呼び出されないことです。
-(void)getZipLocation:(NSNotification *)notification; {
NSLog(@"Zip received and put into array!");
NSArray *location = [notification object];
}
何か案は?前もって感謝します。