js.tinyvm.io
Class ByteWriter
java.lang.Object
js.tinyvm.io.ByteWriter
- All Implemented Interfaces:
- IByteWriter
- Direct Known Subclasses:
- BEByteWriter, LEByteWriter
public abstract class ByteWriter
- extends java.lang.Object
- implements IByteWriter
Basic byte writer implementation (write order independant part)
Constructor Summary |
ByteWriter(java.io.OutputStream stream)
Constructor. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ByteWriter
public ByteWriter(java.io.OutputStream stream)
- Constructor.
- Parameters:
stream
- stream to write to
writeBoolean
public void writeBoolean(boolean aBoolean)
throws java.io.IOException
- Specified by:
writeBoolean
in interface IByteWriter
- Throws:
java.io.IOException
writeByte
public void writeByte(int aByte)
throws java.io.IOException
- Specified by:
writeByte
in interface IByteWriter
- Throws:
java.io.IOException
writeChar
public void writeChar(int aChar)
throws java.io.IOException
- Specified by:
writeChar
in interface IByteWriter
- Throws:
java.io.IOException
writeShort
public void writeShort(int aShort)
throws java.io.IOException
- Specified by:
writeShort
in interface IByteWriter
- Throws:
java.io.IOException
writeInt
public void writeInt(int aInt)
throws java.io.IOException
- Specified by:
writeInt
in interface IByteWriter
- Throws:
java.io.IOException
writeLong
public void writeLong(long aLong)
throws java.io.IOException
- Specified by:
writeLong
in interface IByteWriter
- Throws:
java.io.IOException
writeFloat
public void writeFloat(float aFloat)
throws java.io.IOException
- Specified by:
writeFloat
in interface IByteWriter
- Throws:
java.io.IOException
writeDouble
public void writeDouble(double aDouble)
throws java.io.IOException
- Specified by:
writeDouble
in interface IByteWriter
- Throws:
java.io.IOException
write
public void write(byte[] aBytes)
throws java.io.IOException
- Specified by:
write
in interface IByteWriter
- Throws:
java.io.IOException
write
public void write(int aByte)
throws java.io.IOException
- Specified by:
write
in interface IByteWriter
- Throws:
java.io.IOException
offset
public int offset()
- Current offset in file.
- Specified by:
offset
in interface IByteWriter