title: my SimpleAdapter does not work correctly
body: <p>I have a simple app,and get data in json format from server,by StringBuilder and other tools set my json in a string.my problem is that it show a strange number in each row of my listview.it show 12,6,3,3,6.my json code produce correctly and following is my codes:</p>
  
  <p>myjSONcode that provided:</p>
  
  <pre><code>    {
    "cat": [
      {
        "id": "5",
        "name": "laptop",
        "amount": "12"
      },
      {
        "id": "3",
        "name": "book",
        "amount": "6"
      },
      {
        "id": "1",
        "name": "computer",
        "amount": "3"
      },
      {
        "id": "2",
        "name": "game",
        "amount": "3"
      },
      {
        "id": "4",
        "name": "travel",
        "amount": "6"
      }
    ],
    "success": 1
  </code></pre>
  
  <p>Class CatParser : this class get the json code and parse it to provide for set exracted information from json.</p>
  
  <pre><code>public class CatParser {
  private static String Log_Label = "error";
  
  private static List&lt;HashMap&lt;String, Object&gt;&gt; list_all;
  
  
  public static List&lt;HashMap&lt;String, Object&gt;&gt; parseJson(String json) {
  
      try {
          JSONObject jsonObject = new JSONObject(json);
          JSONArray jArray = jsonObject.getJSONArray("cat");
  
          list_all = new ArrayList&lt;&gt;();
  
  
          for (int i = 0; i &lt; jArray.length(); i++) {
              JSONObject temp = jArray.getJSONObject(i);
  
  
              HashMap&lt;String, Object&gt; cats = new HashMap&lt;&gt;();
              cats.put("id", temp.getString("id"));
              cats.put("name ", temp.getString("name"));
              cats.put("amount", temp.getString("amount"));
  
              list_all.add(cats);
  
          }
      } catch (Exception e) {
          Log.i(Log_Label , "error in Catparser : " + e.toString());
      }
  
  
      return list_all;
  }
  </code></pre>
  
  <p>Class JSONdl :this class connect to the web page of php that produce json codes and get the json code in a format of string.</p>
  
  <pre><code>public class JSONdl {
  private static String Log_Label = "error";
  public static String data = "";
  
  
  public static String JsonIntoString(final String StrlUrl) {
      Thread thread = new Thread(new Runnable() {
          @Override
          public void run() {
              try {
                  URL url = new URL(StrlUrl);
  
  
                  HttpURLConnection connection = (HttpURLConnection) url.openConnection();
  
                  connection.setRequestMethod("GET");
                  connection.setDoInput(true);
                  connection.setReadTimeout(10000);
                  connection.setConnectTimeout(10000);
                  connection.connect();
                  InputStream inputStream = connection.getInputStream();
                  BufferedReader bufferedReader = new BufferedReader(new InputStreamReader(inputStream));
  
                  StringBuilder stringBuilder = new StringBuilder();
                  String line;
  
                  while ((line = bufferedReader.readLine()) != null) {
                      stringBuilder.append(line);
                  }
  
                  data = stringBuilder.toString();
              } catch (Exception e) {
                  Log.i(Log_Label, "error in   JSONdl" + e.toString());
              }
          }
      });
  
      thread.start();
  
      return data;
  }
  </code></pre>
  
  <p>and MainActivity.java : in this class i want to set a simpleAdapter on a listview,but my listview show a strange thing,it shows 12,6,3,3,6 in list view and i can't realize.</p>
  
  <pre><code>public class MainActivity extends AppCompatActivity {
  private String url = "http://172.29.41.174/get_cat.php";
  private static String Log_Label = "error";
  
  
  @Override
  protected void onCreate(Bundle savedInstanceState) {
      super.onCreate(savedInstanceState);
      setContentView(R.layout.activity_main);
  
      setAdapter();
  }
  
  
  private void setAdapter() {
      try {
          String json = JSONdl.JsonIntoString(url);
          List&lt;HashMap&lt;String, Object&gt;&gt; objects = CatParser.parseJson(json);
          String[] from = {String.valueOf(R.mipmap.ic_launcher), "name", "amount"};
          int[] to = {R.id.img, R.id.name, R.id.tedad};
          SimpleAdapter simpleAdapter = new SimpleAdapter(getApplicationContext(), objects, R.layout.row, from, to);
          ListView lst = (ListView) findViewById(R.id.lst);
          lst.setAdapter(simpleAdapter);
      } catch (Exception e) {
          Log.i(Log_Label, "error in recieveJson() in Mainactivity: " + e.toString());
      }
  }
  </code></pre>