我是新的Android开发。我与该应用程序会读取数据的XML文件。我应该在哪里保存这个XML文件?它应该被存储在价值文件夹?
I am new to Android development. I have an XML file with data that the app will read. Where should I keep this XML file? Should it be stored within the "value" folder?
我会说,要看情况。你怎么在你的XML-文件保存?此外,还有一个 RES / XML
-folder,其中XML档案可以保持。但是Android不近XML的文件什么,所以你可能需要阅读我的在哪里把它追索权的小教程。
I'd say that depends. What do you save in your XML-File? There also is a res/xml
-folder, where XML-Files can be kept. But Android does nearly anything with XML-Files, so you might want to read my little Tutorial about where to put which recourses.
此外,还有就是资产
和水库之间的差异
-directory的:
Also, there is a difference between the assets
and the res
-directory's:
研究
级索引的所有资源
并提供了简单的访问。
有一些简单的方法,这
帮助存储在读取文件
RES
-directory
No subdirectorys are allowed under
the specific resource-folders.
The R
-class indexes all resources
and provides simple access.
There are some simple methods which
help reading files stored in the
res
-directory
Subdirectorys被允许(高达
你喜欢)。
在分度号的研究
级
存储在资产阅读资源
使用完成的AssetManager.
Subdirectorys are allowed (as much as
you like).
No indexing by the R
-class
Reading resources stored in assets
is done using the AssetManager.