Answer the question
In order to leave comments, you need to log in
What is better to use to store text data for android?
Hello.
I can not decide how best to store test data on android. I found several options: throw small text pieces on a memory card, put all pieces of text in json, and save it in one file, the same with XML, or use a local mysql database?
The amount of data is average, for example, separate dictionaries will be stored. Each dictionary will store about 30-90 words with a description. Dictionaries can also be unlimited ...
HTML is not suitable ...
Answer the question
In order to leave comments, you need to log in
If the texts are small, you can use localStorage
var prefix = 'my_app_unique_prefix';
var setItem = function( item, value ) {
window.localStorage.setItem( prefix + item, value );
};
var getItem = function( item ) {
return window.localStorage.getItem( prefix + item );
};
setItem( 'testvalue', 'blablabla' );
console.log( getItem( 'testvalue' ) );
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question