FileDocCategorySizeDatePackage
StreamReader.javaAPI DocAndroid 1.5 API1043Wed May 06 22:41:22 BST 2009jdiff

StreamReader

public class StreamReader extends Thread
Reads in lines from an input stream and displays them. See the file LICENSE.txt for copyright details.
author
Matthew Doar, mdoar@pobox.com.

Fields Summary
InputStream
is_
The input stream.
Constructors Summary
StreamReader(InputStream is)
Constructor which takes an InputStream.

        is_ = is;
    
Methods Summary
public voidrun()
Method which is called when this thread is started.

        try {
            InputStreamReader isr = new InputStreamReader(is_);
            BufferedReader br = new BufferedReader(isr);
            String line = null;
            while((line = br.readLine()) != null)
                System.out.println(line);    
        } catch (IOException ioe) {
            System.out.println("IO Error invoking Javadoc");
            ioe.printStackTrace();  
        } catch (Exception e) {
            // Ignore read errors which indicate that the process is complete
        }