美文网首页
ios 通知

ios 通知

作者: 94bu1yang | 来源:发表于2016-05-19 10:08 被阅读0次

//创建通知

NSDictionary*dic =@{@"address":address,@"longitude":longit,@"latitude":latit};

NSNotification*notification =[NSNotificationnotificationWithName:@"tongzhiPlaceAndName"object:niluserInfo:dic];

//通过通知中心发送通知

[[NSNotificationCenterdefaultCenter]postNotification:notification];

//接受来自选择地址的通知

[[NSNotificationCenterdefaultCenter]addObserver:selfselector:@selector(PlaceAndName:)name:@"tongzhiPlaceAndName"object:nil];

相关文章

网友评论

      本文标题:ios 通知

      本文链接:https://www.haomeiwen.com/subject/bsxgrttx.html