Save the lines to a .txt file or put them in a database?

Hey, I have many lines that I use in my application, the .txt file that I use has ~ 14000 lines .. and each 3-10 lines are divided into sections like <String="Chapter I"> ... </String> ..

Speaking of performance / speed, should I put partitions into the database or read line by line through a .txt file and check if the partition number is current? Will it affect speed / performance?

I could also split every ~ 2000 lines into another .txt file so that there are fewer lines to go through. Is this a bad way to store data? Thanks

+3
source share
3 answers

, sqlite . , , , . , , .

+1

Strings Android - res/values ​​/strings.xml( , String , ). Eclipse, R ( ) , :

R.string.mystring

XML:

@string/mystring

, - , :

String string = getString(R.string.hello);

.txt . . ! Android .

+1

This requires a database. Use it.

0
source

All Articles