org.ujmp.core.util.io
Class BufferedRandomAccessFile

java.lang.Object
  extended by java.io.RandomAccessFile
      extended by org.ujmp.core.util.io.BufferedRandomAccessFile
All Implemented Interfaces:
Closeable, DataInput, DataOutput

public class BufferedRandomAccessFile
extends RandomAccessFile


Constructor Summary
BufferedRandomAccessFile(File file, String mode)
           
BufferedRandomAccessFile(File file, String mode, int bufferSize)
           
 
Method Summary
 int read()
           
 int read(byte[] b)
           
 int read(long seek, byte[] b)
           
 void seek(long pos)
           
 void write(long seek, byte[] array)
           
 void writeByte(long seek, byte value)
           
 void writeChar(long seek, char value)
           
 void writeDouble(long seek, double value)
           
 void writeFloat(long seek, float value)
           
 void writeInt(long seek, int value)
           
 void writeLong(long seek, long value)
           
 void writeShort(long seek, short value)
           
 
Methods inherited from class java.io.RandomAccessFile
close, getChannel, getFD, getFilePointer, length, read, readBoolean, readByte, readChar, readDouble, readFloat, readFully, readFully, readInt, readLine, readLong, readShort, readUnsignedByte, readUnsignedShort, readUTF, setLength, skipBytes, write, write, write, writeBoolean, writeByte, writeBytes, writeChar, writeChars, writeDouble, writeFloat, writeInt, writeLong, writeShort, writeUTF
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BufferedRandomAccessFile

public BufferedRandomAccessFile(File file,
                                String mode)
                         throws FileNotFoundException
Throws:
FileNotFoundException

BufferedRandomAccessFile

public BufferedRandomAccessFile(File file,
                                String mode,
                                int bufferSize)
                         throws FileNotFoundException
Throws:
FileNotFoundException
Method Detail

read

public int read()
         throws IOException
Overrides:
read in class RandomAccessFile
Throws:
IOException

seek

public void seek(long pos)
          throws IOException
Overrides:
seek in class RandomAccessFile
Throws:
IOException

read

public int read(byte[] b)
         throws IOException
Overrides:
read in class RandomAccessFile
Throws:
IOException

read

public int read(long seek,
                byte[] b)
         throws IOException
Throws:
IOException

writeByte

public void writeByte(long seek,
                      byte value)
               throws IOException
Throws:
IOException

writeChar

public void writeChar(long seek,
                      char value)
               throws IOException
Throws:
IOException

writeDouble

public void writeDouble(long seek,
                        double value)
                 throws IOException
Throws:
IOException

writeFloat

public void writeFloat(long seek,
                       float value)
                throws IOException
Throws:
IOException

writeShort

public void writeShort(long seek,
                       short value)
                throws IOException
Throws:
IOException

write

public void write(long seek,
                  byte[] array)
           throws IOException
Throws:
IOException

writeInt

public void writeInt(long seek,
                     int value)
              throws IOException
Throws:
IOException

writeLong

public void writeLong(long seek,
                      long value)
               throws IOException
Throws:
IOException


Copyright © 2010. All Rights Reserved.