MCPcopy Create free account
hub / github.com/apache/arrow / garrow_array_import

Function garrow_array_import

c_glib/arrow-glib/basic-array.cpp:860–871  ·  view source on GitHub ↗

* garrow_array_import: * @c_abi_array: (not nullable): A `struct ArrowArray *`. * @data_type: A #GArrowDataType of the C ABI array. * @error: (nullable): Return location for a #GError or %NULL. * * Returns: (transfer full) (nullable): An imported #GArrowArray * on success, %NULL on error. * * You don't need to release the passed `struct ArrowArray *`, * even if this function reports

Source from the content-addressed store, hash-verified

858 * Since: 6.0.0
859 */
860GArrowArray *
861garrow_array_import(gpointer c_abi_array, GArrowDataType *data_type, GError **error)
862{
863 auto arrow_data_type = garrow_data_type_get_raw(data_type);
864 auto arrow_array_result =
865 arrow::ImportArray(static_cast<ArrowArray *>(c_abi_array), arrow_data_type);
866 if (garrow::check(error, arrow_array_result, "[array][import]")) {
867 return garrow_array_new_raw(&(*arrow_array_result));
868 } else {
869 return NULL;
870 }
871}
872
873/**
874 * garrow_array_export:

Callers

nothing calls this directly

Calls 4

garrow_data_type_get_rawFunction · 0.85
garrow_array_new_rawFunction · 0.85
checkFunction · 0.70
ImportArrayFunction · 0.50

Tested by

no test coverage detected