[英]Android Sync Adapter Service not calling onCreate
I am having trouble getting the service started for Sync Adapter and Accounts. 我无法启动针对同步适配器和帐户的服务。 The framework doesn't call
onCreate
methods. 该框架不调用
onCreate
方法。
For Sync Adapter, 对于同步适配器,
I have create following components: 我创建了以下组件:
extends Service
) extends Service
类) extends AbstractThreadedSyncAdapter
) extends AbstractThreadedSyncAdapter
类) extends Service
) extends Service
类) extends AbstractAccountAuthenticator
) extends AbstractAccountAuthenticator
) And updated the entry in the manifest.xml 并更新manifest.xml中的条目
And that's it. 就是这样。
I don't see any logs reported from onCreate
from either services. 我看不到任何服务的
onCreate
报告的任何日志。 Do I have to manually start them? 我必须手动启动它们吗?
Please help. 请帮忙。
Cheers, Raj 干杯,拉吉
I have followed the documents to create 我已按照文档创建
The documents I have followed to write sync adapter are: https://developer.android.com/training/sync-adapters/creating-sync-adapter.html http://blog.udinic.com/2013/04/24/write-your-own-android-authenticator/ https://github.com/Udinic/SyncAdapter/tree/master/SyncAdapterExample 我遵循的编写同步适配器的文档是: https : //developer.android.com/training/sync-adapters/creating-sync-adapter.html http://blog.udinic.com/2013/04/24/ write-your-own-android-authenticator / https://github.com/Udinic/SyncAdapter/tree/master/SyncAdapterExample
我建议您首先从android团队下载并运行Sample SyncAdapter应用。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.