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

Function SortTableOnAllFields

cpp/src/arrow/dataset/test_util_internal.cc:147–155  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

145}
146
147Result<std::shared_ptr<Table>> SortTableOnAllFields(const std::shared_ptr<Table>& tab) {
148 std::vector<SortKey> sort_keys;
149 for (int i = 0; i < tab->num_columns(); i++) {
150 sort_keys.emplace_back(i);
151 }
152 ARROW_ASSIGN_OR_RAISE(auto sort_ids, SortIndices(tab, SortOptions(sort_keys)));
153 ARROW_ASSIGN_OR_RAISE(auto tab_sorted, Take(tab, sort_ids));
154 return tab_sorted.table();
155}
156
157void AssertTablesEqualIgnoringOrder(const std::shared_ptr<Table>& exp,
158 const std::shared_ptr<Table>& act) {

Callers

nothing calls this directly

Calls 2

emplace_backMethod · 0.80
num_columnsMethod · 0.45

Tested by

no test coverage detected