␡
- Overview
- Registering a Client
- Beginning a Sync Session
- Listening for Sync Requests
- Pushing Your Data
- Mingling
- Pulling the Truth
- To Commit or Bail
- Conclusion
Like this article? We recommend
Listening for Sync Requests
On the other end of a sync session is the situation in which another application wants to initiate a sync session, and I want my application to take part in that session. To notify the truth database that an application is interested in joining sync sessions the ISyncClient needs to have an alert handler set:
[syncClient setSyncAlertHandler:self selector:@selector(client:mightWantToSyncEntityNames:)];
When a session is initiated that this client would be interested in, the selector on the handler is called, and the handler is given an opportunity to participate in the session.