MCPcopy Create free account
hub / github.com/bytedance/bolt / toString

Method toString

bolt/core/PlanNode.cpp:2466–2505  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2464}
2465
2466void PlanNode::toString(
2467 std::stringstream& stream,
2468 bool detailed,
2469 bool recursive,
2470 size_t indentationSize,
2471 bool withId,
2472 const std::function<void(
2473 const PlanNodeId& planNodeId,
2474 const std::string& indentation,
2475 std::stringstream& stream)>& addContext) const {
2476 const std::string indentation(indentationSize, ' ');
2477
2478 stream << indentation << "-- " << name();
2479 if (withId) {
2480 stream << "[" << id() << "]";
2481 }
2482
2483 if (detailed) {
2484 stream << "[";
2485 addDetails(stream);
2486 stream << "]";
2487 stream << " -> ";
2488 outputType()->printChildren(stream, ", ");
2489 }
2490 stream << std::endl;
2491
2492 if (addContext) {
2493 auto contextIndentation = indentation + " ";
2494 stream << contextIndentation;
2495 addContext(id(), contextIndentation, stream);
2496 stream << std::endl;
2497 }
2498
2499 if (recursive) {
2500 for (auto& source : sources()) {
2501 source->toString(
2502 stream, detailed, true, indentationSize + 2, withId, addContext);
2503 }
2504 }
2505}
2506
2507namespace {
2508void collectLeafPlanNodeIds(

Callers 13

addKeysFunction · 0.45
addSortingKeysFunction · 0.45
addDetailsMethod · 0.45
ExpandNodeMethod · 0.45
UnnestNodeMethod · 0.45
addWindowFunctionFunction · 0.45
GeneratorNodeMethod · 0.45
helpMessageMethod · 0.45
debugStringFunction · 0.45
testSerdeMethod · 0.45
TEST_FFunction · 0.45
fromBoltTypeFunction · 0.45

Calls 1

printChildrenMethod · 0.80

Tested by 3

debugStringFunction · 0.36
testSerdeMethod · 0.36
TEST_FFunction · 0.36