MCPcopy Create free account
hub / github.com/apache/arrow / mutable_data

Function mutable_data

cpp/src/arrow/buffer.h:251–258  ·  view source on GitHub ↗

\brief Return a writable pointer to the buffer's data The buffer has to be a mutable CPU buffer (`is_cpu()` and `is_mutable()` are true). Otherwise, an assertion may be thrown or a null pointer may be returned. To get the buffer's mutable data address regardless of its device, call `mutable_address()`.

Source from the content-addressed store, hash-verified

249 /// To get the buffer's mutable data address regardless of its device, call
250 /// `mutable_address()`.
251 uint8_t* mutable_data() {
252#ifndef NDEBUG
253 CheckCPU();
254 CheckMutable();
255#endif
256 return ARROW_PREDICT_TRUE(is_cpu_ && is_mutable_) ? const_cast<uint8_t*>(data_)
257 : NULLPTR;
258 }
259
260 /// \brief Return a writable pointer to the buffer's data cast to a specific type
261 ///

Callers 5

~PoolBufferMethod · 0.70
ReserveMethod · 0.70
ResizeMethod · 0.70
ZeroPaddingFunction · 0.70
mutable_data_asFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected