|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.fernsroth.easyio.RandomAccessByteArray
public class RandomAccessByteArray
| Constructor Summary | |
|---|---|
RandomAccessByteArray(byte[] data)
constructor. |
|
| Method Summary | |
|---|---|
long |
getFilePointer()
gets the current location. |
long |
length()
gets the length. |
int |
read()
read a single byte. |
int |
read(byte[] buffer)
|
int |
read(byte[] buffer,
int off,
int len)
|
void |
seek(long newLocation)
sets the location. |
void |
setLength(long length)
sets the length. |
void |
write(byte[] buffer)
writes data. |
void |
write(byte[] buffer,
int start,
int length)
writes data. |
void |
write(int b)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public RandomAccessByteArray(byte[] data)
data - the data.| Method Detail |
|---|
public void seek(long newLocation)
seek in interface IRandomAccessSourcenewLocation - the location.public long getFilePointer()
getFilePointer in interface IRandomAccessSourcepublic void write(int b)
write in interface IOutputStreamb - the data.public void write(byte[] buffer)
write in interface IOutputStreambuffer - the data to write.
public void write(byte[] buffer,
int start,
int length)
write in interface IOutputStreambuffer - the data to write.start - the start.length - the length.public int read()
read in interface IInputStream
public int read(byte[] buffer,
int off,
int len)
read in interface IInputStreambuffer - the buffer to put the data in.off - the offset into buffer to start reading into.len - the length to read.
public int read(byte[] buffer)
read in interface IInputStreambuffer - the buffer to read data into.
public void setLength(long length)
throws java.io.IOException
setLength in interface IRandomAccessSourcelength - the length.
java.io.IOException
public long length()
throws java.io.IOException
length in interface IRandomAccessSourcejava.io.IOException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||