On 13-09-05 2:15 PM, Richard Newman wrote:
If I'm reading this Google doc correctly, there are no restrictions on what
the SyncAdapter can do. It's just a way for the application to get itself
run in the background on some Sync schedule. Is that correct?
A SyncAdapter:
• Gets triggered by the OS at suitable intervals without having to manage
alarms and services.
• Is manifest-linked to certain content providers, such that it can be asked to
sync when they change without any plumbing.
• Comes with free UI in settings, including for each content provider.
• Has a set of linkages to accounts, mechanisms for error reporting, etc. (also
part of the UI stuff).
• Has guarantees about serial execution.
Lots of avoided wheel-reinvention, along with some magic OS-level hooks.
Worth noting that there's really a trifecta in play:
ContentProvider, SyncAdapter, and Account.
A CP provides data that a (many) SyncAdapter syncs (sync), using the
credentials provided by an Account.
So that well-worn groove that rnewman suggests is really even more
well-worn: you need an Account that supports a flow similar to OAuth (if
you care to authenticate to a remote server).
Nick
_______________________________________________
Sync-dev mailing list
[email protected]
https://mail.mozilla.org/listinfo/sync-dev