what will be uri for Sqlite database which is in SDCARD in CursorLoader

≡放荡痞女 提交于 2019-11-30 19:23:16

问题


I am new to android and i have read so many things for best way to load data from an Sqlitedatabase, and from reading blog of Alex Lockwood. I finally decided to go with CursorLoader & LoaderManager.

My problem is that many people want to read data without ContentProvider CursorLoader usage without ContentProvider do not know why they don't want to use ContentProvider can any body suggest me?

If contentprovider is best solution than i just want to make URI for external database. Please, any body know how to make external database which is reside in sdcard? I want to fetch uri of that database or if i put my database in /data/data/packagename/databases/ then how can i fetch it? Please, any body know than suggest me.


回答1:


Kinjal may be You don't need a provider to use an SQLite database if the use is entirely within your own application.

it suggest in android developer site just chk it http://developer.android.com/guide/topics/providers/content-provider-creating.html



来源:https://stackoverflow.com/questions/20419278/what-will-be-uri-for-sqlite-database-which-is-in-sdcard-in-cursorloader

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!