org.simantics.databoard.util.binary
Interface BinaryWriteable

All Superinterfaces:
java.io.DataOutput
All Known Subinterfaces:
RandomAccessBinary
All Known Implementing Classes:
BinaryFile, BinaryMemory, Blob, ByteBufferWriteable, OutputStreamWriteable

public interface BinaryWriteable
extends java.io.DataOutput

Writeable context Common interface for ByteBuffer, byte[], OutputStream, RandomAccessFile.

Author:
Toni Kalajainen (toni.kalajainen@vtt.fi)
See Also:
ByteBufferWriteable, OutputStreamWriteable

Method Summary
 void flush()
          Flush write buffer
 void writeFully(java.nio.ByteBuffer src)
          Put n bytes from the remaining of the byte array.
 void writeFully(java.nio.ByteBuffer src, int length)
          Put n bytes from the remaining of the byte buffer.
 
Methods inherited from interface java.io.DataOutput
write, write, write, writeBoolean, writeByte, writeBytes, writeChar, writeChars, writeDouble, writeFloat, writeInt, writeLong, writeShort, writeUTF
 

Method Detail

writeFully

void writeFully(java.nio.ByteBuffer src)
                throws java.io.IOException
Put n bytes from the remaining of the byte array. This operation moves the pointer in byte buffer.

Parameters:
src -
Throws:
java.io.IOException

writeFully

void writeFully(java.nio.ByteBuffer src,
                int length)
                throws java.io.IOException
Put n bytes from the remaining of the byte buffer. This operation moves the pointer in byte buffer.

Parameters:
src -
length -
Throws:
java.io.IOException

flush

void flush()
           throws java.io.IOException
Flush write buffer

Throws:
java.io.IOException