MCPcopy Create free account
hub / github.com/colbymchenry/codegraph / typeNames

Method typeNames

src/extraction/razor-extractor.ts:136–143  ·  view source on GitHub ↗

* Split a type expression into the capitalized type names it contains — base * type plus any generic arguments (`Bar ` → `Bar`, `Foo`, `Baz`), * each reduced to its last namespace segment. Lowercase/keyword tokens drop out.

(expr: string)

Source from the content-addressed store, hash-verified

134 * each reduced to its last namespace segment. Lowercase/keyword tokens drop out.
135 */
136 private typeNames(expr: string): string[] {
137 const out: string[] = [];
138 for (const raw of expr.split(/[<>,\s]+/)) {
139 const seg = this.lastSegment(raw.trim());
140 if (/^[A-Z][A-Za-z0-9_]*$/.test(seg)) out.push(seg);
141 }
142 return out;
143 }
144
145 private pushRef(componentId: string, name: string, line: number, column: number): void {
146 this.unresolvedReferences.push({

Callers 1

extractDirectivesMethod · 0.95

Calls 2

lastSegmentMethod · 0.95
pushMethod · 0.80

Tested by

no test coverage detected