How to read an http input stream
<p>The code pasted below was taken from java docs on <a href="http://developer.android.com/reference/java/net/HttpURLConnection.html" rel="nofollow">HttpURLConnection</a>.</p>

<p>I get the following error: </p>

<pre><code>readStream(in) 
</code></pre>

<p>as there is no such method.  </p>

<p>I see this same thing in
the Class Overview for URLConnection at
<a href="http://developer.android.com/reference/java/net/URLConnection.html#getInputStream%28%29" rel="nofollow"><code>URLConnection.getInputStream()</code></a></p>

<p>Where is <code>readStream</code>? The code snippet is provided below:</p>

<pre><code> URL url = new URL("http://www.android.com/");   
    HttpURLConnection urlConnection = (HttpURLConnection) url.openConnection();   
    try 
    {     
        InputStream in = new BufferedInputStream(urlConnection.getInputStream());     
        readStream(in);  &lt;-----NO SUCH METHOD
    }
    finally 
    {     
        urlConnection.disconnect();   
    } 
</code></pre>
