Skip to content

Commit 5ebfb32

Browse files
authored
Add capacity() method for TypedBufferBuilder
1 parent 5b73c1c commit 5ebfb32

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

cpp/src/arrow/buffer.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -314,6 +314,7 @@ class ARROW_EXPORT TypedBufferBuilder : public BufferBuilder {
314314

315315
const T* data() const { return reinterpret_cast<const T*>(data_); }
316316
int64_t length() const { return size_ / sizeof(T); }
317+
int64_t capacity() const { return capacity_ / sizeof(T); }
317318
};
318319

319320
/// \brief Allocate a fixed size mutable buffer from a memory pool

0 commit comments

Comments
 (0)