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

Method AppendListOfInferred

cpp/src/arrow/array/array_union_test.cc:465–487  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

463 }
464
465 void AppendListOfInferred(std::shared_ptr<ListArray>* actual) {
466 ListBuilder list_builder(default_memory_pool(), union_builder);
467
468 ASSERT_OK(list_builder.Append());
469 I8 = union_builder->AppendChild(i8_builder, "i8");
470 ASSERT_EQ(I8, 0);
471 AppendInt(10);
472
473 ASSERT_OK(list_builder.Append());
474 STR = union_builder->AppendChild(str_builder, "str");
475 ASSERT_EQ(STR, 1);
476 AppendString("abc");
477 AppendInt(-10);
478
479 ASSERT_OK(list_builder.Append());
480 DBL = union_builder->AppendChild(dbl_builder, "dbl");
481 ASSERT_EQ(DBL, 2);
482 AppendDouble(0.5);
483
484 ASSERT_OK(list_builder.Finish(actual));
485 ASSERT_OK((*actual)->ValidateFull());
486 ArrayFromVector<Int8Type, uint8_t>(expected_types_vector, &expected_types);
487 }
488
489 std::vector<uint8_t> expected_types_vector;
490 std::shared_ptr<Array> expected_types;

Callers

nothing calls this directly

Calls 5

default_memory_poolFunction · 0.85
AppendChildMethod · 0.80
AppendMethod · 0.45
FinishMethod · 0.45
ValidateFullMethod · 0.45

Tested by

no test coverage detected