Which one is faster; Shared Preference or Sqlite Database : <p>This seems to be a common question, but i am unable to find out a straight away answer.</p>

<p>I get <code>JSONObject</code> from server, each activity needs to access it and get some data from it, that's the reason i am more concerned about the performance here. </p>

<p>This is what i do. Following operation runs for each activity.</p>

<pre><code>DatabaseHandler db = new DatabaseHandler(context);
dataObject = db.getAllData();
jsonObject = new JSONObject(dataObject );
value = jsonObject.optString(key);
</code></pre>

<p>The data is pretty straight forward, its a simple <code>JsonObject</code>, i can also put this in <code>sharedPreference</code>, but before moving to <code>sharedPreference</code>, i want to be sure that <code>sharedPreference</code> are faster than <code>sqlite database</code>, or moving to <code>sharedPreference</code> can give me performance improvement. </p>
