(nodes: Node[], title: string, labels?: Map<string, string>)
| 4436 | } |
| 4437 | |
| 4438 | private formatNodeList(nodes: Node[], title: string, labels?: Map<string, string>): string { |
| 4439 | const lines: string[] = [`**${title} (${nodes.length} found)**`, '']; |
| 4440 | |
| 4441 | for (const node of nodes) { |
| 4442 | const location = node.startLine ? `:${node.startLine}` : ''; |
| 4443 | // Compact: just name, kind, location — plus the relationship when it |
| 4444 | // isn't a plain call (callback registration, instantiation, …). |
| 4445 | const label = labels?.get(node.id); |
| 4446 | lines.push( |
| 4447 | `- ${node.name} (${node.kind}) - ${node.filePath}${location}${label ? ` — via ${label}` : ''}` |
| 4448 | ); |
| 4449 | } |
| 4450 | |
| 4451 | return lines.join('\n'); |
| 4452 | } |
| 4453 | |
| 4454 | /** |
| 4455 | * Relationship label for a non-`calls` edge in callers/callees lists. A |
no test coverage detected