Skip to content

Commit

Permalink
Add capacity() method for TypedBufferBuilder
Browse files Browse the repository at this point in the history
  • Loading branch information
xuepanchen authored Jan 16, 2018
1 parent 5b73c1c commit 5ebfb32
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions cpp/src/arrow/buffer.h
Original file line number Diff line number Diff line change
Expand Up @@ -314,6 +314,7 @@ class ARROW_EXPORT TypedBufferBuilder : public BufferBuilder {

const T* data() const { return reinterpret_cast<const T*>(data_); }
int64_t length() const { return size_ / sizeof(T); }
int64_t capacity() const { return capacity_ / sizeof(T); }
};

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

0 comments on commit 5ebfb32

Please sign in to comment.