title: How to parse json string to ArrayList<NameValuePair>
body: <p>I am new to json and need to send some data from server to client. I receive data in client as a json string but need to convert it to <code>ArrayList&lt;NameValuePair&gt;</code>.
  I have tried:</p>
  
  <pre><code>Type type = new TypeToken&lt;ArrayList&lt;NameValuePair&gt;&gt;() {}.getType();
  ArrayList&lt;NameValuePair&gt; arrayList = new Gson().fromJson(response, type);
  </code></pre>
  
  <p>But I it throws exception, so I need a better method to do it. I hope my situation is clear.  All valid answers will be appreciated.</p>