Go to the documentation of this file.
19 #ifndef GRPCPP_IMPL_CODEGEN_PROTO_BUFFER_WRITER_H
20 #define GRPCPP_IMPL_CODEGEN_PROTO_BUFFER_WRITER_H
24 #include <type_traits>
43 class ProtoBufferWriterPeer;
102 size_t allocate_length =
131 if (
count == 0)
return;
181 #endif // GRPCPP_IMPL_CODEGEN_PROTO_BUFFER_WRITER_H
struct grpc_slice_refcount * refcount
virtual void grpc_slice_unref(grpc_slice slice)=0
virtual void grpc_slice_buffer_add(grpc_slice_buffer *sb, grpc_slice slice)=0
struct grpc_byte_buffer::grpc_byte_buffer_data::grpc_compressed_buffer raw
grpc_slice_buffer * slice_buffer()
#define GRPC_SLICE_SET_LENGTH(slice, newlen)
GRPC_CUSTOM_ZEROCOPYOUTPUTSTREAM ZeroCopyOutputStream
void set_byte_count(int64_t byte_count)
const int block_size_
size to alloc for each new grpc_slice needed
~ProtoBufferWriter() override
bool Next(void **data, int *size) override
bool Valid() const
Is this ByteBuffer valid?
CoreCodegenInterface * g_core_codegen_interface
virtual grpc_slice grpc_slice_split_tail(grpc_slice *s, size_t split)=0
virtual grpc_byte_buffer * grpc_raw_byte_buffer_create(grpc_slice *slice, size_t nslices)=0
bool have_backup_
if we are holding a backup slice or not
#define GRPC_SLICE_START_PTR(slice)
void BackUp(int count) override
virtual grpc_slice grpc_slice_malloc(size_t length)=0
int64_t ByteCount() const override
Returns the total number of bytes written since this object was created.
const int kProtoBufferWriterMaxBufferLength
#define GRPC_SLICE_LENGTH(slice)
union grpc_byte_buffer::grpc_byte_buffer_data data
virtual void grpc_slice_buffer_add_indexed(grpc_slice_buffer *sb, grpc_slice slice)=0
grpc_slice_buffer * slice_buffer_
internal buffer of slices holding the serialized data
#define GRPC_SLICE_INLINED_SIZE
virtual void grpc_slice_buffer_pop(grpc_slice_buffer *sb)=0
grpc_slice_buffer slice_buffer
#define GPR_CODEGEN_ASSERT(x)
Codegen specific version of GPR_ASSERT.
void set_buffer(grpc_byte_buffer *buf)
ProtoBufferWriter(ByteBuffer *byte_buffer, int block_size, int total_size)
const int total_size_
byte size of proto being serialized
int64_t byte_count_
bytes written since this object was created
grpc_slice slice_
current slice passed back to the caller
grpc
Author(s):
autogenerated on Thu Mar 13 2025 03:00:56