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

Function garrow_feather_file_reader_read_names

c_glib/arrow-glib/reader.cpp:873–891  ·  view source on GitHub ↗

* garrow_feather_file_reader_read_names: * @reader: A #GArrowFeatherFileReader. * @names: (array length=n_names): The names of column to be read. * @n_names: The number of names. * @error: (nullable): Return location for a #GError or %NULL. * * Returns: (transfer full): The table in the file that has only the * specified columns. * * Since: 0.12.0 */

Source from the content-addressed store, hash-verified

871 * Since: 0.12.0
872 */
873GArrowTable *
874garrow_feather_file_reader_read_names(GArrowFeatherFileReader *reader,
875 const gchar **names,
876 guint n_names,
877 GError **error)
878{
879 auto arrow_reader = garrow_feather_file_reader_get_raw(reader);
880 std::vector<std::string> cpp_names;
881 for (guint i = 0; i < n_names; ++i) {
882 cpp_names.push_back(names[i]);
883 }
884 std::shared_ptr<arrow::Table> arrow_table;
885 auto status = arrow_reader->Read(cpp_names, &arrow_table);
886 if (garrow_error_check(error, status, "[feather-file-reader][read-names]")) {
887 return garrow_table_new_raw(&arrow_table);
888 } else {
889 return NULL;
890 }
891}
892
893struct GArrowCSVReadOptionsPrivate
894{

Callers

nothing calls this directly

Calls 4

garrow_error_checkFunction · 0.85
push_backMethod · 0.80
ReadMethod · 0.45

Tested by

no test coverage detected