com.servingxml.components.flatfile.scanner.bytes
Class ByteBufferImpl
java.lang.Object
com.servingxml.components.flatfile.scanner.bytes.ByteBufferImpl
- All Implemented Interfaces:
- ByteBuffer
public class ByteBufferImpl
- extends java.lang.Object
- implements ByteBuffer
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
BLOCK_LENGTH
protected static final int BLOCK_LENGTH
- See Also:
- Constant Field Values
buffer
protected byte[] buffer
start
protected int start
length
protected int length
maxLength
protected int maxLength
position
protected int position
reserved
protected int reserved
ByteBufferImpl
public ByteBufferImpl(java.io.InputStream is)
read
protected void read(int n)
throws java.io.IOException
- Throws:
java.io.IOException
getPosition
public int getPosition()
- Specified by:
getPosition
in interface ByteBuffer
setPosition
public void setPosition(int position)
- Specified by:
setPosition
in interface ByteBuffer
getReserved
public int getReserved()
- Specified by:
getReserved
in interface ByteBuffer
setReserved
public void setReserved(int reserved)
- Specified by:
setReserved
in interface ByteBuffer
maxLength
public int maxLength()
- Specified by:
maxLength
in interface ByteBuffer
next
public void next()
throws java.io.IOException
- Specified by:
next
in interface ByteBuffer
- Throws:
java.io.IOException
next
public void next(int n)
throws java.io.IOException
- Specified by:
next
in interface ByteBuffer
- Throws:
java.io.IOException
done
public boolean done()
- Specified by:
done
in interface ByteBuffer
eof
protected boolean eof()
current
public byte current()
- Specified by:
current
in interface ByteBuffer
grow
protected void grow(int n)
buffer
public byte[] buffer()
- Specified by:
buffer
in interface ByteBuffer
start
public int start()
- Specified by:
start
in interface ByteBuffer
length
public int length()
- Specified by:
length
in interface ByteBuffer
startsWith
public boolean startsWith(byte[] prefix)
throws java.io.IOException
- Specified by:
startsWith
in interface ByteBuffer
- Throws:
java.io.IOException
clear
public void clear()
- Specified by:
clear
in interface ByteBuffer