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

Method Path

cpp/src/arrow/json/parser.cc:746–762  ·  view source on GitHub ↗

\brief Emit path of current field for debugging purposes

Source from the content-addressed store, hash-verified

744
745 /// \brief Emit path of current field for debugging purposes
746 std::string Path() {
747 std::string path;
748 for (size_t i = 0; i < builder_stack_.size(); ++i) {
749 auto builder = builder_stack_[i];
750 if (builder.kind == Kind::kArray) {
751 path += "/[]";
752 } else {
753 auto struct_builder = Cast<Kind::kObject>(builder);
754 auto field_index = field_index_;
755 if (i + 1 < field_index_stack_.size()) {
756 field_index = field_index_stack_[i + 1];
757 }
758 path += "/" + std::string(struct_builder->field_name(field_index));
759 }
760 }
761 return path;
762 }
763
764 protected:
765 template <typename Handler, typename Stream>

Calls 2

field_nameMethod · 0.80
sizeMethod · 0.45

Tested by 15

test_localfs_file_infoFunction · 0.36
test_hdfs_optionsFunction · 0.36
test_write_tableFunction · 0.36
resource_rootFunction · 0.36
tempdirFunction · 0.36