Class AsyncProtobufLogWriter.OutputStreamWrapper
java.lang.Object
java.io.OutputStream
org.apache.hadoop.hbase.regionserver.wal.AsyncProtobufLogWriter.OutputStreamWrapper
- All Implemented Interfaces:
Closeable
,Flushable
,AutoCloseable
,ByteBufferWriter
- Enclosing class:
- AsyncProtobufLogWriter
private static final class AsyncProtobufLogWriter.OutputStreamWrapper
extends OutputStream
implements ByteBufferWriter
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
close()
void
write
(byte[] b, int off, int len) void
write
(int b) void
write
(ByteBuffer b, int off, int len) Writeslen
bytes from the specified ByteBuffer starting at offsetoff
void
writeInt
(int i) Writes anint
to the underlying output stream as four bytes, high byte first.Methods inherited from class java.io.OutputStream
flush, write
-
Field Details
-
out
-
oneByteBuf
-
-
Constructor Details
-
OutputStreamWrapper
-
-
Method Details
-
write
- Specified by:
write
in classOutputStream
- Throws:
IOException
-
write
Description copied from interface:ByteBufferWriter
Writeslen
bytes from the specified ByteBuffer starting at offsetoff
- Specified by:
write
in interfaceByteBufferWriter
- Parameters:
b
- the data.off
- the start offset in the data.len
- the number of bytes to write.- Throws:
IOException
- if an I/O error occurs.
-
writeInt
Description copied from interface:ByteBufferWriter
Writes anint
to the underlying output stream as four bytes, high byte first.- Specified by:
writeInt
in interfaceByteBufferWriter
- Parameters:
i
- theint
to write- Throws:
IOException
- if an I/O error occurs.
-
write
- Overrides:
write
in classOutputStream
- Throws:
IOException
-
close
- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
- Overrides:
close
in classOutputStream
- Throws:
IOException
-