MCPcopy Create free account
hub / github.com/Acode-Foundation/Acode / processSymbolInformation

Function processSymbolInformation

src/cm/lsp/documentSymbols.ts:164–187  ·  view source on GitHub ↗
(
	symbol: SymbolInformation,
	depth = 0,
)

Source from the content-addressed store, hash-verified

162}
163
164function processSymbolInformation(
165 symbol: SymbolInformation,
166 depth = 0,
167): ProcessedSymbol {
168 return {
169 name: symbol.name,
170 kind: symbol.kind,
171 kindName: getSymbolKindName(symbol.kind),
172 range: {
173 startLine: symbol.location.range.start.line,
174 startCharacter: symbol.location.range.start.character,
175 endLine: symbol.location.range.end.line,
176 endCharacter: symbol.location.range.end.character,
177 },
178 selectionRange: {
179 startLine: symbol.location.range.start.line,
180 startCharacter: symbol.location.range.start.character,
181 endLine: symbol.location.range.end.line,
182 endCharacter: symbol.location.range.end.character,
183 },
184 containerName: symbol.containerName,
185 depth,
186 };
187}
188
189function flattenSymbols(
190 symbols: ProcessedSymbol[],

Callers 1

fetchDocumentSymbolsFunction · 0.85

Calls 1

getSymbolKindNameFunction · 0.85

Tested by

no test coverage detected