public final class RandomAccessIO
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
protected java.lang.String |
name |
protected Writer |
ra |
Constructor and Description |
---|
RandomAccessIO(Writer ra,
java.lang.String name) |
Modifier and Type | Method and Description |
---|---|
void |
close() |
void |
deleteOnExit() |
protected void |
finalize() |
Writer |
getRA() |
long |
length() |
java.lang.String |
name() |
byte |
readByte(long pos) |
void |
readFully(long pos,
byte[] b,
int off,
int len) |
int |
readInt(long pos) |
long |
readLong(long pos) |
short |
readShort(long pos) |
private static byte[] |
space(int count) |
void |
write(long pos,
byte[] b) |
void |
write(long pos,
byte[] b,
int off,
int len) |
void |
writeByte(long pos,
int v) |
void |
writeInt(long pos,
int v) |
void |
writeLong(long pos,
long v) |
void |
writeShort(long pos,
int v) |
void |
writeSpace(long pos,
int spaceCount) |
protected final Writer ra
protected final java.lang.String name
public RandomAccessIO(Writer ra, java.lang.String name)
public final Writer getRA()
public final long length() throws java.io.IOException
java.io.IOException
public final void readFully(long pos, byte[] b, int off, int len) throws java.io.IOException
java.io.IOException
public final void write(long pos, byte[] b, int off, int len) throws java.io.IOException
java.io.IOException
public final java.lang.String name()
public final byte readByte(long pos) throws java.io.IOException
java.io.IOException
public final void writeByte(long pos, int v) throws java.io.IOException
java.io.IOException
public final short readShort(long pos) throws java.io.IOException
java.io.IOException
public final void writeShort(long pos, int v) throws java.io.IOException
java.io.IOException
public final int readInt(long pos) throws java.io.IOException
java.io.IOException
public final void writeInt(long pos, int v) throws java.io.IOException
java.io.IOException
public final long readLong(long pos) throws java.io.IOException
java.io.IOException
public final void writeLong(long pos, long v) throws java.io.IOException
java.io.IOException
public final void write(long pos, byte[] b) throws java.io.IOException
java.io.IOException
public final void writeSpace(long pos, int spaceCount) throws java.io.IOException
java.io.IOException
private static final byte[] space(int count)
public final void close() throws java.io.IOException
java.io.IOException
protected final void finalize() throws java.lang.Throwable
finalize
in class java.lang.Object
java.lang.Throwable
public final void deleteOnExit()