Search code examples
androidjsonperformancesqlitewp-api

Is it better to parse json every time in android


I am creating an android ecommerce app with WP REST API and the json I get from that API, I need to store it for offline purpose. So what is a better approach save parsed data in to sqlite and just show it from there or save the json string and parse it every time it needs to be shown?


Solution

  • No, you must only parse before adding that to sqlite. Why to do extra same work every time. Not only it is time consuming but also memory over head for conversion.