title: Android: Jsoup: GET put all items on ListView
body: <p>If doc isn't null i want to put all data from doc to ListView, how do it?
  If to write Element = doc.select("someSelector"); then i can't to put it in ListView;</p>
  
  <p>Sorry for my english(i'am Russian)</p>
  
  <p>Code: </p>
  
  <pre class="lang-java prettyprint-override"><code>package com.example.phpfunctions;
  
  import java.io.IOException;
  import java.util.Locale;
  
  import org.jsoup.Jsoup;
  import org.jsoup.nodes.Document;
  import org.jsoup.select.Elements;
  
  import android.app.Activity;
  import android.os.AsyncTask;
  import android.os.Bundle;
  import android.view.Menu;
  import android.widget.AutoCompleteTextView;
  import android.widget.ListView;
  import android.widget.Toast;
  
  public class MainActivity extends Activity {
  
      private final String lang = Locale.getDefault().getLanguage();
      private final String functions_list = "someURL";
      private final ListView lv = (ListView) findViewById(R.id.listView1);
      Document doc = null;
      AutoCompleteTextView input;
  
      @Override
      protected void onCreate(Bundle savedInstanceState) {
          super.onCreate(savedInstanceState);
          setContentView(R.layout.activity_main);
  
          new getData().execute(functions_list);
  
          if(doc != null)
          {
  
              //--Write code here--//
  
          }
          else
              Toast.makeText(this, "error", Toast.LENGTH_LONG).show();
      }
  
      @Override
      public boolean onCreateOptionsMenu(Menu menu) {
          // Inflate the menu; this adds items to the action bar if it is present.
          getMenuInflater().inflate(R.menu.main, menu);
          return true;
      }
  
  
      class getData extends AsyncTask&lt;String, Void, Document&gt; {
  
          protected Document doInBackground(String... urls) {
  
              try {
                  Document data = Jsoup.connect(urls[0]).get();
                  return data;
              } catch (IOException e) {
                  // TODO Auto-generated catch block
                  e.printStackTrace();
  
                  return null;
              }
  
  
  
          }
  
          protected void onPreExecute() {
          }
  
          protected void onPostExecute(Document result) {
              doc = result;
          }
  
      }
  
  }
  </code></pre>