MCPcopy Create free account
hub / github.com/apache/fory / bind_output_stream

Method bind_output_stream

cpp/fory/util/buffer.h:119–130  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

117 }
118
119 FORY_ALWAYS_INLINE void bind_output_stream(OutputStream *output_stream) {
120 if (output_stream_ == output_stream) {
121 return;
122 }
123 if (output_stream_ != nullptr) {
124 output_stream_->unbind_buffer(this);
125 }
126 output_stream_ = output_stream;
127 if (output_stream_ != nullptr) {
128 output_stream_->bind_buffer(this);
129 }
130 }
131
132 FORY_ALWAYS_INLINE void clear_output_stream() {
133 if (output_stream_ == nullptr) {

Calls 2

unbind_bufferMethod · 0.80
bind_bufferMethod · 0.45