Last active
August 29, 2015 14:06
-
-
Save sstadelman/650f41e21d8cc38a7b8a to your computer and use it in GitHub Desktop.
NSNotification subscribe for request notification
This file contains hidden or 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
| - (void) loadModel | |
| { | |
| NSString *accountRequestNotificationIdentifier = @"AccountRequest"; | |
| [[NSNotificationCenter defaultCenter] addObserverForName:accountRequestNotificationIdentifier object:nil queue:[NSOperationQueue mainQueue] usingBlock:^(NSNotification *note) { | |
| //update the Accounts model | |
| }]; | |
| id<SODataRequestExecution> requestExecution = [myStore scheduleReadEntitySet:@"Accounts" delegate:self options:nil]; | |
| requestExecution.request.customTag = accountRequestNotificationIdentifier; | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment