@InterfaceAudience.Private public class ByteBufferDataWriter extends DataOutputStream
Constructor and Description |
---|
ByteBufferDataWriter(NativeDataTarget handler) |
Modifier and Type | Method and Description |
---|---|
void |
close() |
void |
flush() |
boolean |
hasUnFlushedData()
Check whether there is unflushed data stored in the stream
|
boolean |
shortOfSpace(int dataLength)
Check whether this buffer has enough space to store length of bytes
|
void |
write(byte[] b,
int off,
int len) |
void |
write(int v) |
void |
writeBoolean(boolean v) |
void |
writeByte(int v) |
void |
writeBytes(String s) |
void |
writeChar(int v) |
void |
writeChars(String s) |
void |
writeDouble(double v) |
void |
writeFloat(float v) |
void |
writeInt(int v) |
void |
writeLong(long v) |
void |
writeShort(int v) |
void |
writeUTF(String str) |
write
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
write
public ByteBufferDataWriter(NativeDataTarget handler)
public void write(int v) throws IOException
write
in interface DataOutput
write
in class OutputStream
IOException
public boolean shortOfSpace(int dataLength) throws IOException
DataOutputStream
shortOfSpace
in class DataOutputStream
dataLength
- length of bytesIOException
public void write(byte[] b, int off, int len) throws IOException
write
in interface DataOutput
write
in class OutputStream
IOException
public void flush() throws IOException
flush
in interface Flushable
flush
in class OutputStream
IOException
public void close() throws IOException
close
in interface Closeable
close
in interface AutoCloseable
close
in class OutputStream
IOException
public final void writeBoolean(boolean v) throws IOException
IOException
public final void writeByte(int v) throws IOException
IOException
public final void writeShort(int v) throws IOException
IOException
public final void writeChar(int v) throws IOException
IOException
public final void writeInt(int v) throws IOException
IOException
public final void writeLong(long v) throws IOException
IOException
public final void writeFloat(float v) throws IOException
IOException
public final void writeDouble(double v) throws IOException
IOException
public final void writeBytes(String s) throws IOException
IOException
public final void writeChars(String s) throws IOException
IOException
public final void writeUTF(String str) throws IOException
IOException
public boolean hasUnFlushedData()
DataOutputStream
hasUnFlushedData
in class DataOutputStream
Copyright © 2008–2024 Apache Software Foundation. All rights reserved.