[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Nested List examples?

This language was also discussed in

We should try to be consistent about terminology in all implementations:

* A buffer is a contiguous block of memory without any defined
semantics (it's just bytes)
* An array or vector (we've been saying "array" in C++ because
"vector" has a size-mutability connotation there) is a logical 1D
sequence of values, represented by an arbitrary number of buffers

- Wes

On Thu, May 3, 2018 at 8:35 AM, Antoine Pitrou <antoine@xxxxxxxxxx> wrote:
> Le 03/05/2018 à 14:28, Andy Grove a écrit :
>> Now I have even more questions.
>> List<List<T>> uses one values buffer for the instances of T (according to
>> List<Struct> couldn't possibly do that. Is that a valid type in Arrow?
> I think you misread the layout document: it says a list array has
> """A values array, a child array of type T. T may also be a nested
> type""".  Note: child array, not buffer.
> So, yes, List<Struct> is a valid type. A List<Struct> array has:
> * one null bitmap buffer (optional) to designate null lists
> * one offsets buffer for list offsets
> * one child struct array (which has an arbitrary number of buffers
> depending on the struct type)
> Regards
> Antoine.