Created
December 5, 2013 08:53
-
-
Save rizumita/7802174 to your computer and use it in GitHub Desktop.
NSNotificationCenter/NSNotificationをReactiveCocoaで利用する方法。selfが解放される時に自動的に通知が停止する。
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[[[[NSNotificationCenter defaultCenter] rac_addObserverForName:notification object:nil] takeUntil:[self rac_willDeallocSignal]] subscribeNext:^(NSNotification *notification) { | |
NSLog(@"%@", notification); | |
}]; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment