clickDetector
Class WindowsFile

java.lang.Object
  extended by java.io.RandomAccessFile
      extended by clickDetector.WindowsFile
All Implemented Interfaces:
ReadWinFile, WriteWinFile, java.io.Closeable, java.io.DataInput, java.io.DataOutput

public class WindowsFile
extends java.io.RandomAccessFile
implements WriteWinFile, ReadWinFile

Author:
doug Gillespie

Some additions to RandomAccessFile to write binary data that is compatible with the RainbowClick file format.


Constructor Summary
WindowsFile(java.io.File file, java.lang.String mode)
           
WindowsFile(java.lang.String file, java.lang.String mode)
           
 
Method Summary
 double readWinDouble()
           
 float readWinFloat()
           
 int readWinInt()
          Read a Windows 32 bit integer
 long readWinLong()
           
 int readWinShort()
           
 void writeWinDouble(double val)
           
 void writeWinFloat(float val)
           
 void writeWinInt(int val)
           
 void writeWinLong(long longValue)
           
 void writeWinShort(int val)
           
 
Methods inherited from class java.io.RandomAccessFile
close, getChannel, getFD, getFilePointer, length, read, read, read, readBoolean, readByte, readChar, readDouble, readFloat, readFully, readFully, readInt, readLine, readLong, readShort, readUnsignedByte, readUnsignedShort, readUTF, seek, 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
 
Methods inherited from interface clickDetector.WriteWinFile
writeByte
 
Methods inherited from interface clickDetector.ReadWinFile
readByte
 

Constructor Detail

WindowsFile

public WindowsFile(java.lang.String file,
                   java.lang.String mode)
            throws java.io.IOException
Throws:
java.io.IOException

WindowsFile

public WindowsFile(java.io.File file,
                   java.lang.String mode)
            throws java.io.IOException
Throws:
java.io.IOException
Method Detail

writeWinInt

public void writeWinInt(int val)
                 throws java.io.IOException
Specified by:
writeWinInt in interface WriteWinFile
Throws:
java.io.IOException

readWinInt

public int readWinInt()
               throws java.io.IOException
Read a Windows 32 bit integer

Specified by:
readWinInt in interface ReadWinFile
Throws:
java.io.IOException

writeWinShort

public void writeWinShort(int val)
                   throws java.io.IOException
Specified by:
writeWinShort in interface WriteWinFile
Throws:
java.io.IOException

readWinShort

public int readWinShort()
                 throws java.io.IOException
Specified by:
readWinShort in interface ReadWinFile
Throws:
java.io.IOException

writeWinFloat

public void writeWinFloat(float val)
                   throws java.io.IOException
Specified by:
writeWinFloat in interface WriteWinFile
Throws:
java.io.IOException

readWinFloat

public float readWinFloat()
                   throws java.io.IOException
Specified by:
readWinFloat in interface ReadWinFile
Throws:
java.io.IOException

writeWinDouble

public void writeWinDouble(double val)
                    throws java.io.IOException
Specified by:
writeWinDouble in interface WriteWinFile
Throws:
java.io.IOException

readWinDouble

public double readWinDouble()
                     throws java.io.IOException
Specified by:
readWinDouble in interface ReadWinFile
Throws:
java.io.IOException

writeWinLong

public void writeWinLong(long longValue)
                  throws java.io.IOException
Specified by:
writeWinLong in interface WriteWinFile
Throws:
java.io.IOException

readWinLong

public long readWinLong()
                 throws java.io.IOException
Specified by:
readWinLong in interface ReadWinFile
Throws:
java.io.IOException