MCPcopy Index your code
hub / github.com/PatrickSys/codebase-context / addCandidate

Function addCandidate

src/tools/search-codebase.ts:444–450  ·  view source on GitHub ↗
(file: string, hop: 1 | 2, line?: number)

Source from the content-addressed store, hash-verified

442 const candidates = new Map<string, ImpactCandidate>();
443
444 const addCandidate = (file: string, hop: 1 | 2, line?: number): void => {
445 const existing = candidates.get(file);
446 if (existing) {
447 if (existing.hop <= hop) return;
448 }
449 candidates.set(file, { file, hop, ...(line ? { line } : {}) });
450 };
451
452 const collectImporters = (
453 target: string

Callers 1

computeImpactCandidatesFunction · 0.85

Calls 2

setMethod · 0.80
getMethod · 0.45

Tested by

no test coverage detected