Reading an downloaded XML file on android
<p>I am currently downloading data from a website (of my own creation) in XML format directly into my database on an android tablet.  I am using:</p>

<pre><code>Xml.parse(getData(parm),Xml.Encoding.ISO_8859_1, handler);
</code></pre>

<p>where getData is:</p>

<pre><code>HttpClient client = new DefaultHttpClient();
HttpGet request = new HttpGet(new URI(myurl));
HttpResponse response = client.execute(request);
return response.getEntity().getContent();
</code></pre>

<p>This works pretty well, except it does not always complete correctly.  Can anyone suggest a better way to download the data into a file, and then parse that instead.  Bonus points if it can tell the data fully downloaded correctly, or could restart a partial download.</p>

<p>Thanks!!</p>
