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

Method TotalBufferSize

cpp/src/arrow/datum.cc:118–134  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

116}
117
118int64_t Datum::TotalBufferSize() const {
119 switch (this->kind()) {
120 case Datum::ARRAY:
121 return util::TotalBufferSize(*std::get<std::shared_ptr<ArrayData>>(this->value));
122 case Datum::CHUNKED_ARRAY:
123 return util::TotalBufferSize(*std::get<std::shared_ptr<ChunkedArray>>(this->value));
124 case Datum::RECORD_BATCH:
125 return util::TotalBufferSize(*std::get<std::shared_ptr<RecordBatch>>(this->value));
126 case Datum::TABLE:
127 return util::TotalBufferSize(*std::get<std::shared_ptr<Table>>(this->value));
128 case Datum::SCALAR:
129 return 0;
130 default:
131 DCHECK(false);
132 return 0;
133 }
134}
135
136int64_t Datum::null_count() const {
137 if (this->kind() == Datum::ARRAY) {

Callers 1

TESTFunction · 0.45

Calls 2

TotalBufferSizeFunction · 0.85
kindMethod · 0.45

Tested by 1

TESTFunction · 0.36