com.alarexgroup.m2mplf.util
Class BufferedReader

java.lang.Object
  extended by java.io.Reader
      extended by com.alarexgroup.m2mplf.util.BufferedReader
All Implemented Interfaces:
java.io.Closeable, java.lang.Readable
public class BufferedReader
extends java.io.Reader

Internal class ported from JAVA JDK 1.4.1

Field Summary
 
Fields inherited from class java.io.Reader
lock
 
Constructor Summary
BufferedReader(java.io.Reader in)
          Create a buffering character-input stream that uses a default-sized input buffer.
BufferedReader(java.io.Reader in, int sz)
          Create a buffering character-input stream that uses an input buffer of the specified size.
 
Method Summary
 void close()
           
 int read()
          Read a single character.
 int read(char[] cbuf, int off, int len)
           
 java.lang.String readLine()
           
 
Methods inherited from class java.io.Reader
mark, markSupported, read, read, ready, reset, skip
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BufferedReader

public BufferedReader(java.io.Reader in,
                      int sz)
Create a buffering character-input stream that uses an input buffer of the specified size.

Parameters:
in - A Reader
sz - Input-buffer size
Throws:
java.lang.IllegalArgumentException - If sz is <= 0

BufferedReader

public BufferedReader(java.io.Reader in)
Create a buffering character-input stream that uses a default-sized input buffer.

Parameters:
in - A Reader
Method Detail

read

public int read()
         throws java.io.IOException
Read a single character.

Overrides:
read in class java.io.Reader
Returns:
The character read, as an integer in the range 0 to 65535 (0x00-0xffff), or -1 if the end of the stream has been reached
Throws:
java.io.IOException - If an I/O error occurs

read

public int read(char[] cbuf,
                int off,
                int len)
         throws java.io.IOException
Specified by:
read in class java.io.Reader
Throws:
java.io.IOException

readLine

public java.lang.String readLine()
                          throws java.io.IOException
Throws:
java.io.IOException

close

public void close()
           throws java.io.IOException
Specified by:
close in interface java.io.Closeable
Specified by:
close in class java.io.Reader
Throws:
java.io.IOException