Package com.google.protobuf
Class CodedOutputStream.HeapNioEncoder
java.lang.Object
com.google.protobuf.ByteOutput
com.google.protobuf.CodedOutputStream
com.google.protobuf.CodedOutputStream.ArrayEncoder
com.google.protobuf.CodedOutputStream.HeapNioEncoder
- Enclosing class:
CodedOutputStream
A
CodedOutputStream
that writes directly to a heap ByteBuffer
. Writes are done
directly to the underlying array. The buffer position is only updated after a flush.-
Nested Class Summary
Nested classes/interfaces inherited from class com.google.protobuf.CodedOutputStream
CodedOutputStream.OutOfSpaceException
-
Field Summary
FieldsFields inherited from class com.google.protobuf.CodedOutputStream
DEFAULT_BUFFER_SIZE, LITTLE_ENDIAN_32_SIZE, wrapper
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
flush()
Flushes the stream and forces any buffered bytes to be written.Methods inherited from class com.google.protobuf.CodedOutputStream.ArrayEncoder
getTotalBytesWritten, spaceLeft, write, write, write, writeBool, writeByteArray, writeByteArray, writeByteArrayNoTag, writeByteBuffer, writeBytes, writeBytesNoTag, writeFixed32, writeFixed32NoTag, writeFixed64, writeFixed64NoTag, writeInt32, writeInt32NoTag, writeLazy, writeLazy, writeMessage, writeMessage, writeMessageNoTag, writeMessageNoTag, writeMessageSetExtension, writeRawBytes, writeRawMessageSetExtension, writeString, writeStringNoTag, writeTag, writeUInt32, writeUInt32NoTag, writeUInt64, writeUInt64NoTag
Methods inherited from class com.google.protobuf.CodedOutputStream
checkNoSpaceLeft, computeBoolSize, computeBoolSizeNoTag, computeByteArraySize, computeByteArraySizeNoTag, computeByteBufferSize, computeByteBufferSizeNoTag, computeBytesSize, computeBytesSizeNoTag, computeDoubleSize, computeDoubleSizeNoTag, computeEnumSize, computeEnumSizeNoTag, computeFixed32Size, computeFixed32SizeNoTag, computeFixed64Size, computeFixed64SizeNoTag, computeFloatSize, computeFloatSizeNoTag, computeGroupSize, computeGroupSize, computeGroupSizeNoTag, computeGroupSizeNoTag, computeInt32Size, computeInt32SizeNoTag, computeInt64Size, computeInt64SizeNoTag, computeLazyFieldMessageSetExtensionSize, computeLazyFieldSize, computeLazyFieldSizeNoTag, computeLengthDelimitedFieldSize, computeMessageSetExtensionSize, computeMessageSize, computeMessageSize, computeMessageSizeNoTag, computeMessageSizeNoTag, computePreferredBufferSize, computeRawMessageSetExtensionSize, computeRawVarint32Size, computeRawVarint64Size, computeSFixed32Size, computeSFixed32SizeNoTag, computeSFixed64Size, computeSFixed64SizeNoTag, computeSInt32Size, computeSInt32SizeNoTag, computeSInt64Size, computeSInt64SizeNoTag, computeStringSize, computeStringSizeNoTag, computeTagSize, computeUInt32Size, computeUInt32SizeNoTag, computeUInt64Size, computeUInt64SizeNoTag, encodeZigZag32, encodeZigZag64, inefficientWriteStringNoTag, isSerializationDeterministic, newInstance, newInstance, newInstance, newInstance, newInstance, newInstance, newInstance, newSafeInstance, newUnsafeInstance, useDeterministicSerialization, writeBoolNoTag, writeByteArrayNoTag, writeDouble, writeDoubleNoTag, writeEnum, writeEnumNoTag, writeFloat, writeFloatNoTag, writeGroup, writeGroup, writeGroupNoTag, writeGroupNoTag, writeInt64, writeInt64NoTag, writeRawByte, writeRawByte, writeRawBytes, writeRawBytes, writeRawBytes, writeRawLittleEndian32, writeRawLittleEndian64, writeRawVarint32, writeRawVarint64, writeSFixed32, writeSFixed32NoTag, writeSFixed64, writeSFixed64NoTag, writeSInt32, writeSInt32NoTag, writeSInt64, writeSInt64NoTag
-
Field Details
-
byteBuffer
-
initialPosition
private int initialPosition
-
-
Constructor Details
-
HeapNioEncoder
HeapNioEncoder(ByteBuffer byteBuffer)
-
-
Method Details
-
flush
public void flush()Description copied from class:CodedOutputStream
Flushes the stream and forces any buffered bytes to be written. This does not flush the underlying OutputStream.- Overrides:
flush
in classCodedOutputStream.ArrayEncoder
-