title: Json string to realm objects, fastest way
body: <p>I have the following code that I am running in an AsyncTask. It works well but the following lines seem to make it 3-5 seconds slower when used. Is there a faster way to convert my json string into realm?</p>
  
  <pre><code>    //Load the local model data. params[0].toString() is a json string loaded from SharedPreferences.
      JsonParser jsonParser = new JsonParser();
      JsonObject o = (JsonObject)jsonParser.parse(params[0].toString());
  
      Realm realmThread = Realm.getInstance(visnetawrap.appModel);
  
      //work orders, total entries of 4000.
      JsonArray openWorkOrders = o.getAsJsonArray("work_orders");
  
      //Convert the lists so they can be used with realm.
      List&lt;OpenOrderObject&gt; woList = visnetawrap.gsonClient.fromJson(openWorkOrders.toString(), new TypeToken&lt;List&lt;OpenOrderObject&gt;&gt;() {
      }.getType());
      realmThread.beginTransaction();
      realmThread.copyToRealm(woList);
      realmThread.commitTransaction();
  </code></pre>