You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by GitBox <gi...@apache.org> on 2020/07/09 19:58:15 UTC

[GitHub] [arrow] bkietz commented on a change in pull request #7691: ARROW-8655: [Python][Dataset] Provide helper method to get keys from a partition expression

bkietz commented on a change in pull request #7691:
URL: https://github.com/apache/arrow/pull/7691#discussion_r452456433



##########
File path: python/pyarrow/includes/libarrow_dataset.pxd
##########
@@ -314,6 +314,10 @@ cdef extern from "arrow/dataset/api.h" namespace "arrow::dataset" nogil:
             const CExpression& partition_expression,
             CRecordBatchProjector* projector)
 
+    cdef CResult[unordered_map[c_string, shared_ptr[CScalar]]] \
+        CGetPartitionKeys "arrow::dataset::KeyValuePartitioning::GetKeys"(

Review comment:
       Yes, as far as cython is concerned a static method can be treated as a free function. `CSetPartitionKeysInProjector` (decl above this one) is another example. I think it works the other way, too: a c++ free function can be exposed as a `@staticmethod` of a cppclass (but haven't got a standing example and I'm not sure why we'd ever need that)




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org