public interface DataOutputPlus
extends java.io.DataOutput
Modifier and Type | Method and Description |
---|---|
default boolean |
hasPosition()
If the implementation supports providing a position, this method returns
true , otherwise false . |
default long |
position()
Returns the current position of the underlying target like a file-pointer
or the position withing a buffer.
|
void |
write(java.nio.ByteBuffer buffer) |
default void |
write(ReadableMemory memory,
long offset,
long length) |
default void |
writeBytes(long register,
int bytes)
An efficient way to write the type
bytes of a long |
default void |
writeUnsignedVInt(long i)
This is more efficient for storing unsigned values, both in storage and CPU burden.
|
default void |
writeVInt(long i) |
void write(java.nio.ByteBuffer buffer) throws java.io.IOException
java.io.IOException
default void write(ReadableMemory memory, long offset, long length) throws java.io.IOException
java.io.IOException
default void writeVInt(long i) throws java.io.IOException
java.io.IOException
default void writeUnsignedVInt(long i) throws java.io.IOException
java.io.IOException
default void writeBytes(long register, int bytes) throws java.io.IOException
bytes
of a longregister
- - the long value to be writtenbytes
- - the number of bytes the register occupies. Valid values are between 1 and 8 inclusive.java.io.IOException
default long position()
hasPosition()
.java.lang.UnsupportedOperationException
- if the implementation does not support
positiondefault boolean hasPosition()
true
, otherwise false
.Copyright © 2009-2022 The Apache Software Foundation