[
https://issues.apache.org/jira/browse/ARROW-602?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15929991#comment-15929991
]
Johan Mabille edited comment on ARROW-602 at 3/20/17 1:19 AM:
--------------------------------------------------------------
Ok, so it is possible to provide an STL compliant iterator. Cool !
EDIT: still a little problem, the value_type is unknown at compilation, so it
might be usefull to add it as a template parameter of ChunkedArray. Besides,
that would allow type checking in its constructor.
I think most of the use cases would be to apply STL-like algorithms, so it
makes sense to iterate over non-null values only. Later we can provide a "full"
iteration interface for the case where iteration over null values is required,
what do you think ?
was (Author: johanmabille):
Ok, so it is possible to provide an STL compliant iterator. Cool !
EDIT: still a little problem, the value_type is unknown at compilation, so it
might be usefull to add it as a template parameter of ChunkedArray. Besides,
that you allows type checking in the its constructor
I think most of the use cases would be to apply STL-like algorithms, so it
makes sense to iterate over non-null values only. Later we can provide a "full"
iteration interface for the case where iteration over null values is required,
what do you think ?
> C++: Provide iterator access to primitive elements inside a
> Column/ChunkedArray
> -------------------------------------------------------------------------------
>
> Key: ARROW-602
> URL: https://issues.apache.org/jira/browse/ARROW-602
> Project: Apache Arrow
> Issue Type: Improvement
> Components: C++
> Reporter: Uwe L. Korn
> Labels: beginner, newbie
>
> Given a ChunkedArray, an Arrow user must currently iterate over all its
> chunks and then cast them to their types to extract the primitive memory
> regions to access the values. A convenient way to access the underlying
> values would be to offer a function that takes a ChunkedArray and returns a
> C++ iterator over all elements.
> While this may not be the most performant way to access the underlying data,
> it should have sufficient performance and adds a convenience layer for new
> users.
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)