MySQL Connector/J size='-1'>5.0.8

com.mysql.jdbc.util
Class ReadAheadInputStream

java.lang.Object
  extended byjava.io.InputStream
      extended bycom.mysql.jdbc.util.ReadAheadInputStream

public class ReadAheadInputStream
extends java.io.InputStream

A non-blocking buffered input stream. Reads more if it can, won't block to fill the buffer, only blocks to satisfy a request of read(byte[])

Version:
$Id: ReadAheadInputStream.java,v 1.1.2.1 2005/05/13 18:58:39 mmatthews Exp $
Author:
Mark Matthews

Field Summary
protected  int currentPosition
           
protected  boolean doDebug
           
protected  int endOfCurrentData
           
protected  Log log
           
 
Constructor Summary
ReadAheadInputStream(java.io.InputStream toBuffer, boolean debug, Log logTo)
           
ReadAheadInputStream(java.io.InputStream toBuffer, int bufferSize, boolean debug, Log logTo)
           
 
Method Summary
 int available()
           
 void close()
           
 boolean markSupported()
           
 int read()
           
 int read(byte[] b, int off, int len)
           
 long skip(long n)
           
 
Methods inherited from class java.io.InputStream
mark, read, reset
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

endOfCurrentData

protected int endOfCurrentData

currentPosition

protected int currentPosition

doDebug

protected boolean doDebug

log

protected Log log
Constructor Detail

ReadAheadInputStream

public ReadAheadInputStream(java.io.InputStream toBuffer,
                            boolean debug,
                            Log logTo)

ReadAheadInputStream

public ReadAheadInputStream(java.io.InputStream toBuffer,
                            int bufferSize,
                            boolean debug,
                            Log logTo)
Method Detail

read

public int read(byte[] b,
                int off,
                int len)
         throws java.io.IOException
Throws:
java.io.IOException

read

public int read()
         throws java.io.IOException
Throws:
java.io.IOException

available

public int available()
              throws java.io.IOException
Throws:
java.io.IOException

close

public void close()
           throws java.io.IOException
Throws:
java.io.IOException

markSupported

public boolean markSupported()

skip

public long skip(long n)
          throws java.io.IOException
Throws:
java.io.IOException

MySQL Connector/J size='-1'>5.0.8