which is better way to get an xml returned from web request for parsing
<p><em><strong>I need to read an xml output returned from a php file through a web request in my android app.</em></strong></p>

<p>Hence, I have used Asynctask to read the xml file as byte by byte storing in a byte type array in background 
thread and then put the array in a text file. After completing the async task, I have used SAX perser to parse
the xml reading from the text file.</p>

<p>There is another way to do the same thing as below where complete xml is stored in a String variable:</p>

<pre><code>DefaultHttpClient httpClient = new DefaultHttpClient();
HttpPost httpPost = new HttpPost("http://www.abcdefgh./abc/efg.php");
HttpResponse httpResponse = httpClient.execute(httpPost);
HttpEntity httpEntity = httpResponse.getEntity();
String line = EntityUtils.toString(httpEntity);
</code></pre>

<p>Here line variable contains the whole xml as a long string. <strong>Could any one explain which one is better/effecient from above two procedure to do the job ......?</strong></p>
