通知

//创建通知
[[NSNotificationCenter defaultCenter] postNotificationName:City_Change_Notification object:nil];
//接收通知
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(goodsMortgageHttpRequest) name:City_Change_Notification object:nil];
//移除通知
#pragma mark ==================   Dealloc   ==================
- (void)dealloc {
    [[NSNotificationCenter defaultCenter] removeObserver:self];
    NSLog(@"===  GoodsMortgageViewController dealloc  ===");
}

你可能感兴趣的:(通知)