jj-language-server 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (99) hide show
  1. package/LICENSE +191 -0
  2. package/README.md +170 -0
  3. package/lib/cli.d.ts +2 -0
  4. package/lib/cli.d.ts.map +1 -0
  5. package/lib/cli.mjs +3 -0
  6. package/lib/cli.mjs.map +1 -0
  7. package/lib/diagnostics.d.ts +7 -0
  8. package/lib/diagnostics.d.ts.map +1 -0
  9. package/lib/features/call-hierarchy.d.ts +11 -0
  10. package/lib/features/call-hierarchy.d.ts.map +1 -0
  11. package/lib/features/code-actions.d.ts +10 -0
  12. package/lib/features/code-actions.d.ts.map +1 -0
  13. package/lib/features/code-lens.d.ts +8 -0
  14. package/lib/features/code-lens.d.ts.map +1 -0
  15. package/lib/features/completion.d.ts +8 -0
  16. package/lib/features/completion.d.ts.map +1 -0
  17. package/lib/features/document-links.d.ts +6 -0
  18. package/lib/features/document-links.d.ts.map +1 -0
  19. package/lib/features/document-symbols.d.ts +7 -0
  20. package/lib/features/document-symbols.d.ts.map +1 -0
  21. package/lib/features/folding-ranges.d.ts +9 -0
  22. package/lib/features/folding-ranges.d.ts.map +1 -0
  23. package/lib/features/formatting.d.ts +13 -0
  24. package/lib/features/formatting.d.ts.map +1 -0
  25. package/lib/features/hover.d.ts +8 -0
  26. package/lib/features/hover.d.ts.map +1 -0
  27. package/lib/features/inlay-hints.d.ts +8 -0
  28. package/lib/features/inlay-hints.d.ts.map +1 -0
  29. package/lib/features/linked-editing.d.ts +10 -0
  30. package/lib/features/linked-editing.d.ts.map +1 -0
  31. package/lib/features/navigation.d.ts +35 -0
  32. package/lib/features/navigation.d.ts.map +1 -0
  33. package/lib/features/on-type-formatting.d.ts +7 -0
  34. package/lib/features/on-type-formatting.d.ts.map +1 -0
  35. package/lib/features/organize-imports.d.ts +6 -0
  36. package/lib/features/organize-imports.d.ts.map +1 -0
  37. package/lib/features/refactoring.d.ts +31 -0
  38. package/lib/features/refactoring.d.ts.map +1 -0
  39. package/lib/features/selection-range.d.ts +9 -0
  40. package/lib/features/selection-range.d.ts.map +1 -0
  41. package/lib/features/semantic-diagnostics.d.ts +14 -0
  42. package/lib/features/semantic-diagnostics.d.ts.map +1 -0
  43. package/lib/features/semantic-tokens.d.ts +12 -0
  44. package/lib/features/semantic-tokens.d.ts.map +1 -0
  45. package/lib/features/signature-help.d.ts +7 -0
  46. package/lib/features/signature-help.d.ts.map +1 -0
  47. package/lib/features/source-generation.d.ts +7 -0
  48. package/lib/features/source-generation.d.ts.map +1 -0
  49. package/lib/features/token-utils.d.ts +6 -0
  50. package/lib/features/token-utils.d.ts.map +1 -0
  51. package/lib/features/type-hierarchy.d.ts +7 -0
  52. package/lib/features/type-hierarchy.d.ts.map +1 -0
  53. package/lib/java/annotation-processor.d.ts +57 -0
  54. package/lib/java/annotation-processor.d.ts.map +1 -0
  55. package/lib/java/class-file-reader.d.ts +57 -0
  56. package/lib/java/class-file-reader.d.ts.map +1 -0
  57. package/lib/java/cst-utils.d.ts +33 -0
  58. package/lib/java/cst-utils.d.ts.map +1 -0
  59. package/lib/java/expression-type-resolver.d.ts +24 -0
  60. package/lib/java/expression-type-resolver.d.ts.map +1 -0
  61. package/lib/java/import-resolver.d.ts +40 -0
  62. package/lib/java/import-resolver.d.ts.map +1 -0
  63. package/lib/java/javadoc.d.ts +41 -0
  64. package/lib/java/javadoc.d.ts.map +1 -0
  65. package/lib/java/parser.d.ts +13 -0
  66. package/lib/java/parser.d.ts.map +1 -0
  67. package/lib/java/scope-resolver.d.ts +20 -0
  68. package/lib/java/scope-resolver.d.ts.map +1 -0
  69. package/lib/java/symbol-table.d.ts +43 -0
  70. package/lib/java/symbol-table.d.ts.map +1 -0
  71. package/lib/java/type-resolver.d.ts +73 -0
  72. package/lib/java/type-resolver.d.ts.map +1 -0
  73. package/lib/lsp-client.d.ts +14 -0
  74. package/lib/lsp-client.d.ts.map +1 -0
  75. package/lib/lsp-connection.d.ts +6 -0
  76. package/lib/lsp-connection.d.ts.map +1 -0
  77. package/lib/lsp-server.d.ts +87 -0
  78. package/lib/lsp-server.d.ts.map +1 -0
  79. package/lib/project/classpath-resolver.d.ts +80 -0
  80. package/lib/project/classpath-resolver.d.ts.map +1 -0
  81. package/lib/project/document-cache.d.ts +58 -0
  82. package/lib/project/document-cache.d.ts.map +1 -0
  83. package/lib/project/gradle.d.ts +32 -0
  84. package/lib/project/gradle.d.ts.map +1 -0
  85. package/lib/project/jar-index.d.ts +71 -0
  86. package/lib/project/jar-index.d.ts.map +1 -0
  87. package/lib/project/jdk-model.d.ts +39 -0
  88. package/lib/project/jdk-model.d.ts.map +1 -0
  89. package/lib/project/maven.d.ts +37 -0
  90. package/lib/project/maven.d.ts.map +1 -0
  91. package/lib/project/multi-root.d.ts +52 -0
  92. package/lib/project/multi-root.d.ts.map +1 -0
  93. package/lib/project/source-jar.d.ts +62 -0
  94. package/lib/project/source-jar.d.ts.map +1 -0
  95. package/lib/project/workspace-index.d.ts +67 -0
  96. package/lib/project/workspace-index.d.ts.map +1 -0
  97. package/lib/utils/logger.d.ts +18 -0
  98. package/lib/utils/logger.d.ts.map +1 -0
  99. package/package.json +57 -0
@@ -0,0 +1,7 @@
1
+ import lsp from 'vscode-languageserver';
2
+ import type { ParseError } from './java/parser.js';
3
+ /**
4
+ * Convert parse errors from java-parser into LSP Diagnostic objects.
5
+ */
6
+ export declare function parseErrorsToDiagnostics(errors: ParseError[]): lsp.Diagnostic[];
7
+ //# sourceMappingURL=diagnostics.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"diagnostics.d.ts","sourceRoot":"","sources":["../src/diagnostics.ts"],"names":[],"mappings":"AAQA,OAAO,GAAG,MAAM,uBAAuB,CAAC;AACxC,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAEnD;;GAEG;AACH,wBAAgB,wBAAwB,CAAC,MAAM,EAAE,UAAU,EAAE,GAAG,GAAG,CAAC,UAAU,EAAE,CAkB/E"}
@@ -0,0 +1,11 @@
1
+ import lsp from 'vscode-languageserver';
2
+ import type { CstNode } from 'chevrotain';
3
+ import type { SymbolTable } from '../java/symbol-table.js';
4
+ import type { WorkspaceIndex } from '../project/workspace-index.js';
5
+ /**
6
+ * Provide call hierarchy for incoming and outgoing calls.
7
+ */
8
+ export declare function prepareCallHierarchy(cst: CstNode, table: SymbolTable, uri: string, line: number, character: number): lsp.CallHierarchyItem[] | null;
9
+ export declare function provideIncomingCalls(cst: CstNode, table: SymbolTable, uri: string, item: lsp.CallHierarchyItem, workspaceIndex?: WorkspaceIndex): lsp.CallHierarchyIncomingCall[];
10
+ export declare function provideOutgoingCalls(cst: CstNode, table: SymbolTable, uri: string, item: lsp.CallHierarchyItem, workspaceIndex?: WorkspaceIndex): lsp.CallHierarchyOutgoingCall[];
11
+ //# sourceMappingURL=call-hierarchy.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"call-hierarchy.d.ts","sourceRoot":"","sources":["../../src/features/call-hierarchy.ts"],"names":[],"mappings":"AAQA,OAAO,GAAG,MAAM,uBAAuB,CAAC;AACxC,OAAO,KAAK,EAAE,OAAO,EAAsB,MAAM,YAAY,CAAC;AAC9D,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAG3D,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,+BAA+B,CAAC;AAEpE;;GAEG;AAEH,wBAAgB,oBAAoB,CAChC,GAAG,EAAE,OAAO,EACZ,KAAK,EAAE,WAAW,EAClB,GAAG,EAAE,MAAM,EACX,IAAI,EAAE,MAAM,EACZ,SAAS,EAAE,MAAM,GAClB,GAAG,CAAC,iBAAiB,EAAE,GAAG,IAAI,CAkBhC;AAED,wBAAgB,oBAAoB,CAChC,GAAG,EAAE,OAAO,EACZ,KAAK,EAAE,WAAW,EAClB,GAAG,EAAE,MAAM,EACX,IAAI,EAAE,GAAG,CAAC,iBAAiB,EAC3B,cAAc,CAAC,EAAE,cAAc,GAChC,GAAG,CAAC,yBAAyB,EAAE,CAkBjC;AAmCD,wBAAgB,oBAAoB,CAChC,GAAG,EAAE,OAAO,EACZ,KAAK,EAAE,WAAW,EAClB,GAAG,EAAE,MAAM,EACX,IAAI,EAAE,GAAG,CAAC,iBAAiB,EAC3B,cAAc,CAAC,EAAE,cAAc,GAChC,GAAG,CAAC,yBAAyB,EAAE,CAkBjC"}
@@ -0,0 +1,10 @@
1
+ import lsp from 'vscode-languageserver';
2
+ import type { CstNode } from 'chevrotain';
3
+ import type { SymbolTable } from '../java/symbol-table.js';
4
+ /**
5
+ * Provide code actions (quick fixes) for diagnostics and context.
6
+ */
7
+ export declare function provideCodeActions(cst: CstNode, table: SymbolTable, text: string, uri: string, range: lsp.Range, _context: {
8
+ diagnostics: lsp.Diagnostic[];
9
+ }): lsp.CodeAction[];
10
+ //# sourceMappingURL=code-actions.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"code-actions.d.ts","sourceRoot":"","sources":["../../src/features/code-actions.ts"],"names":[],"mappings":"AAQA,OAAO,GAAG,MAAM,uBAAuB,CAAC;AACxC,OAAO,KAAK,EAAE,OAAO,EAAsB,MAAM,YAAY,CAAC;AAC9D,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAM3D;;GAEG;AACH,wBAAgB,kBAAkB,CAC9B,GAAG,EAAE,OAAO,EACZ,KAAK,EAAE,WAAW,EAClB,IAAI,EAAE,MAAM,EACZ,GAAG,EAAE,MAAM,EACX,KAAK,EAAE,GAAG,CAAC,KAAK,EAChB,QAAQ,EAAE;IAAE,WAAW,EAAE,GAAG,CAAC,UAAU,EAAE,CAAA;CAAE,GAC5C,GAAG,CAAC,UAAU,EAAE,CA+ElB"}
@@ -0,0 +1,8 @@
1
+ import lsp from 'vscode-languageserver';
2
+ import type { CstNode } from 'chevrotain';
3
+ import type { SymbolTable } from '../java/symbol-table.js';
4
+ /**
5
+ * Provide code lens (reference counts above declarations).
6
+ */
7
+ export declare function provideCodeLens(cst: CstNode, table: SymbolTable, uri: string): lsp.CodeLens[];
8
+ //# sourceMappingURL=code-lens.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"code-lens.d.ts","sourceRoot":"","sources":["../../src/features/code-lens.ts"],"names":[],"mappings":"AAQA,OAAO,GAAG,MAAM,uBAAuB,CAAC;AACxC,OAAO,KAAK,EAAE,OAAO,EAAsB,MAAM,YAAY,CAAC;AAC9D,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAG3D;;GAEG;AACH,wBAAgB,eAAe,CAC3B,GAAG,EAAE,OAAO,EACZ,KAAK,EAAE,WAAW,EAClB,GAAG,EAAE,MAAM,GACZ,GAAG,CAAC,QAAQ,EAAE,CAyBhB"}
@@ -0,0 +1,8 @@
1
+ import lsp from 'vscode-languageserver';
2
+ import type { SymbolTable } from '../java/symbol-table.js';
3
+ import { type JavadocComment } from '../java/javadoc.js';
4
+ /**
5
+ * Provide completion items at the given position.
6
+ */
7
+ export declare function provideCompletions(table: SymbolTable, line: number, character: number, text?: string, javadocMap?: Map<number, JavadocComment>): lsp.CompletionItem[];
8
+ //# sourceMappingURL=completion.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"completion.d.ts","sourceRoot":"","sources":["../../src/features/completion.ts"],"names":[],"mappings":"AAQA,OAAO,GAAG,MAAM,uBAAuB,CAAC;AACxC,OAAO,KAAK,EAAE,WAAW,EAAc,MAAM,yBAAyB,CAAC;AAGvE,OAAO,EAAyB,KAAK,cAAc,EAAE,MAAM,oBAAoB,CAAC;AAkGhF;;GAEG;AACH,wBAAgB,kBAAkB,CAC9B,KAAK,EAAE,WAAW,EAClB,IAAI,EAAE,MAAM,EACZ,SAAS,EAAE,MAAM,EACjB,IAAI,CAAC,EAAE,MAAM,EACb,UAAU,CAAC,EAAE,GAAG,CAAC,MAAM,EAAE,cAAc,CAAC,GACzC,GAAG,CAAC,cAAc,EAAE,CA4ItB"}
@@ -0,0 +1,6 @@
1
+ import type { DocumentLink } from 'vscode-languageserver';
2
+ /**
3
+ * Finds clickable URLs in comments and strings within the source text.
4
+ */
5
+ export declare function provideDocumentLinks(sourceText: string): DocumentLink[];
6
+ //# sourceMappingURL=document-links.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"document-links.d.ts","sourceRoot":"","sources":["../../src/features/document-links.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAC;AAI1D;;GAEG;AACH,wBAAgB,oBAAoB,CAAC,UAAU,EAAE,MAAM,GAAG,YAAY,EAAE,CAyBvE"}
@@ -0,0 +1,7 @@
1
+ import lsp from 'vscode-languageserver';
2
+ import type { CstNode } from 'chevrotain';
3
+ /**
4
+ * Extract document symbols (outline) from a java-parser CST.
5
+ */
6
+ export declare function extractDocumentSymbols(cst: CstNode): lsp.DocumentSymbol[];
7
+ //# sourceMappingURL=document-symbols.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"document-symbols.d.ts","sourceRoot":"","sources":["../../src/features/document-symbols.ts"],"names":[],"mappings":"AAQA,OAAO,GAAG,MAAM,uBAAuB,CAAC;AACxC,OAAO,KAAK,EAAE,OAAO,EAAsB,MAAM,YAAY,CAAC;AAG9D;;GAEG;AACH,wBAAgB,sBAAsB,CAAC,GAAG,EAAE,OAAO,GAAG,GAAG,CAAC,cAAc,EAAE,CAoBzE"}
@@ -0,0 +1,9 @@
1
+ import lsp from 'vscode-languageserver';
2
+ import type { CstNode } from 'chevrotain';
3
+ /**
4
+ * Compute folding ranges from a java-parser CST.
5
+ * Supports: class/interface/enum/record bodies, method bodies, blocks,
6
+ * import groups, multi-line comments, and javadoc.
7
+ */
8
+ export declare function computeFoldingRanges(cst: CstNode, text: string): lsp.FoldingRange[];
9
+ //# sourceMappingURL=folding-ranges.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"folding-ranges.d.ts","sourceRoot":"","sources":["../../src/features/folding-ranges.ts"],"names":[],"mappings":"AAQA,OAAO,GAAG,MAAM,uBAAuB,CAAC;AACxC,OAAO,KAAK,EAAE,OAAO,EAAsB,MAAM,YAAY,CAAC;AAG9D;;;;GAIG;AACH,wBAAgB,oBAAoB,CAAC,GAAG,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,GAAG,GAAG,CAAC,YAAY,EAAE,CAanF"}
@@ -0,0 +1,13 @@
1
+ import lsp from 'vscode-languageserver';
2
+ import { TextDocument } from 'vscode-languageserver-textdocument';
3
+ /**
4
+ * Format a full Java document using Prettier with prettier-plugin-java.
5
+ */
6
+ export declare function formatDocument(document: TextDocument, options: lsp.FormattingOptions): Promise<lsp.TextEdit[]>;
7
+ /**
8
+ * Format a range within a Java document.
9
+ * Falls back to formatting the full document since prettier-plugin-java
10
+ * does not support range formatting natively.
11
+ */
12
+ export declare function formatRange(document: TextDocument, range: lsp.Range, options: lsp.FormattingOptions): Promise<lsp.TextEdit[]>;
13
+ //# sourceMappingURL=formatting.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"formatting.d.ts","sourceRoot":"","sources":["../../src/features/formatting.ts"],"names":[],"mappings":"AAQA,OAAO,GAAG,MAAM,uBAAuB,CAAC;AACxC,OAAO,EAAE,YAAY,EAAE,MAAM,oCAAoC,CAAC;AAiBlE;;GAEG;AACH,wBAAsB,cAAc,CAChC,QAAQ,EAAE,YAAY,EACtB,OAAO,EAAE,GAAG,CAAC,iBAAiB,GAC/B,OAAO,CAAC,GAAG,CAAC,QAAQ,EAAE,CAAC,CAuBzB;AAED;;;;GAIG;AACH,wBAAsB,WAAW,CAC7B,QAAQ,EAAE,YAAY,EACtB,KAAK,EAAE,GAAG,CAAC,KAAK,EAChB,OAAO,EAAE,GAAG,CAAC,iBAAiB,GAC/B,OAAO,CAAC,GAAG,CAAC,QAAQ,EAAE,CAAC,CAIzB"}
@@ -0,0 +1,8 @@
1
+ import lsp from 'vscode-languageserver';
2
+ import type { SymbolTable } from '../java/symbol-table.js';
3
+ import type { CstNode } from 'chevrotain';
4
+ /**
5
+ * Provide hover information for a symbol at the given position.
6
+ */
7
+ export declare function provideHover(cst: CstNode, table: SymbolTable, text: string, line: number, character: number): lsp.Hover | null;
8
+ //# sourceMappingURL=hover.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"hover.d.ts","sourceRoot":"","sources":["../../src/features/hover.ts"],"names":[],"mappings":"AAQA,OAAO,GAAG,MAAM,uBAAuB,CAAC;AACxC,OAAO,KAAK,EAAE,WAAW,EAAc,MAAM,yBAAyB,CAAC;AAIvE,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,YAAY,CAAC;AAG1C;;GAEG;AACH,wBAAgB,YAAY,CACxB,GAAG,EAAE,OAAO,EACZ,KAAK,EAAE,WAAW,EAClB,IAAI,EAAE,MAAM,EACZ,IAAI,EAAE,MAAM,EACZ,SAAS,EAAE,MAAM,GAClB,GAAG,CAAC,KAAK,GAAG,IAAI,CA6ClB"}
@@ -0,0 +1,8 @@
1
+ import lsp from 'vscode-languageserver';
2
+ import type { CstNode } from 'chevrotain';
3
+ import type { SymbolTable } from '../java/symbol-table.js';
4
+ /**
5
+ * Provide inlay hints (parameter names, inferred types).
6
+ */
7
+ export declare function provideInlayHints(cst: CstNode, table: SymbolTable, range: lsp.Range): lsp.InlayHint[];
8
+ //# sourceMappingURL=inlay-hints.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"inlay-hints.d.ts","sourceRoot":"","sources":["../../src/features/inlay-hints.ts"],"names":[],"mappings":"AAQA,OAAO,GAAG,MAAM,uBAAuB,CAAC;AACxC,OAAO,KAAK,EAAE,OAAO,EAAsB,MAAM,YAAY,CAAC;AAC9D,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAI3D;;GAEG;AACH,wBAAgB,iBAAiB,CAC7B,GAAG,EAAE,OAAO,EACZ,KAAK,EAAE,WAAW,EAClB,KAAK,EAAE,GAAG,CAAC,KAAK,GACjB,GAAG,CAAC,SAAS,EAAE,CAUjB"}
@@ -0,0 +1,10 @@
1
+ import type { LinkedEditingRanges } from 'vscode-languageserver';
2
+ import type { SymbolTable } from '../java/symbol-table.js';
3
+ import type { ParseResult } from '../java/parser.js';
4
+ /**
5
+ * Provides linked editing ranges for simultaneous identifier renaming.
6
+ * When the cursor is on an identifier, returns all positions of that same
7
+ * identifier in the file so they can be edited simultaneously.
8
+ */
9
+ export declare function provideLinkedEditingRanges(parseResult: ParseResult, symbolTable: SymbolTable, sourceText: string, line: number, column: number): LinkedEditingRanges | null;
10
+ //# sourceMappingURL=linked-editing.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"linked-editing.d.ts","sourceRoot":"","sources":["../../src/features/linked-editing.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AACjE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAC3D,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAKrD;;;;GAIG;AACH,wBAAgB,0BAA0B,CACtC,WAAW,EAAE,WAAW,EACxB,WAAW,EAAE,WAAW,EACxB,UAAU,EAAE,MAAM,EAClB,IAAI,EAAE,MAAM,EACZ,MAAM,EAAE,MAAM,GACf,mBAAmB,GAAG,IAAI,CAkB5B"}
@@ -0,0 +1,35 @@
1
+ import lsp from 'vscode-languageserver';
2
+ import type { CstNode } from 'chevrotain';
3
+ import type { SymbolTable } from '../java/symbol-table.js';
4
+ /**
5
+ * Go to definition: find the declaration of the symbol under the cursor.
6
+ */
7
+ export declare function provideDefinition(cst: CstNode, table: SymbolTable, uri: string, line: number, character: number): lsp.Location | null;
8
+ /**
9
+ * Find all references to the symbol under the cursor within the file.
10
+ * If searchName is provided, find all references to that name (used for cross-file search).
11
+ */
12
+ export declare function provideReferences(cst: CstNode, table: SymbolTable, uri: string, line: number, character: number, searchName?: string): lsp.Location[];
13
+ /**
14
+ * Highlight all occurrences of the symbol under the cursor.
15
+ */
16
+ export declare function provideDocumentHighlight(cst: CstNode, table: SymbolTable, line: number, character: number): lsp.DocumentHighlight[];
17
+ /**
18
+ * Rename the symbol under the cursor across the file.
19
+ */
20
+ export declare function provideRename(cst: CstNode, table: SymbolTable, uri: string, line: number, character: number, newName: string): lsp.WorkspaceEdit | null;
21
+ /**
22
+ * Prepare rename: return the range of the symbol that would be renamed.
23
+ */
24
+ export declare function providePrepareRename(cst: CstNode, table: SymbolTable, line: number, character: number): lsp.Range | null;
25
+ import type { WorkspaceIndex } from '../project/workspace-index.js';
26
+ /**
27
+ * Go to implementation: find classes implementing an interface or overriding a method.
28
+ * Searches across the workspace index for types that extend/implement the symbol under cursor.
29
+ */
30
+ export declare function provideImplementation(cst: CstNode, table: SymbolTable, uri: string, line: number, character: number, workspaceIndex: WorkspaceIndex): lsp.Location[];
31
+ /**
32
+ * Go to type definition: jump to the type declaration of a variable/field/parameter.
33
+ */
34
+ export declare function provideTypeDefinition(cst: CstNode, table: SymbolTable, uri: string, line: number, character: number, workspaceIndex: WorkspaceIndex): lsp.Location | null;
35
+ //# sourceMappingURL=navigation.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"navigation.d.ts","sourceRoot":"","sources":["../../src/features/navigation.ts"],"names":[],"mappings":"AAQA,OAAO,GAAG,MAAM,uBAAuB,CAAC;AACxC,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,YAAY,CAAC;AAC1C,OAAO,KAAK,EAAE,WAAW,EAAc,MAAM,yBAAyB,CAAC;AAgBvE;;GAEG;AACH,wBAAgB,iBAAiB,CAC7B,GAAG,EAAE,OAAO,EACZ,KAAK,EAAE,WAAW,EAClB,GAAG,EAAE,MAAM,EACX,IAAI,EAAE,MAAM,EACZ,SAAS,EAAE,MAAM,GAClB,GAAG,CAAC,QAAQ,GAAG,IAAI,CAWrB;AAED;;;GAGG;AACH,wBAAgB,iBAAiB,CAC7B,GAAG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CAoCrB"}
@@ -0,0 +1,7 @@
1
+ import lsp from 'vscode-languageserver';
2
+ /**
3
+ * Provide on-type formatting: auto-indent after opening brace,
4
+ * auto-close brace after enter, and semicolon formatting.
5
+ */
6
+ export declare function provideOnTypeFormatting(text: string, position: lsp.Position, ch: string, options: lsp.FormattingOptions): lsp.TextEdit[];
7
+ //# sourceMappingURL=on-type-formatting.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"on-type-formatting.d.ts","sourceRoot":"","sources":["../../src/features/on-type-formatting.ts"],"names":[],"mappings":"AAQA,OAAO,GAAG,MAAM,uBAAuB,CAAC;AAExC;;;GAGG;AACH,wBAAgB,uBAAuB,CACnC,IAAI,EAAE,MAAM,EACZ,QAAQ,EAAE,GAAG,CAAC,QAAQ,EACtB,EAAE,EAAE,MAAM,EACV,OAAO,EAAE,GAAG,CAAC,iBAAiB,GAC/B,GAAG,CAAC,QAAQ,EAAE,CAiBhB"}
@@ -0,0 +1,6 @@
1
+ import lsp from 'vscode-languageserver';
2
+ /**
3
+ * Organize imports: sort, remove unused, and group imports.
4
+ */
5
+ export declare function organizeImports(text: string, _uri: string): lsp.TextEdit[];
6
+ //# sourceMappingURL=organize-imports.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"organize-imports.d.ts","sourceRoot":"","sources":["../../src/features/organize-imports.ts"],"names":[],"mappings":"AAQA,OAAO,GAAG,MAAM,uBAAuB,CAAC;AAExC;;GAEG;AACH,wBAAgB,eAAe,CAAC,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,GAAG,GAAG,CAAC,QAAQ,EAAE,CAuE1E"}
@@ -0,0 +1,31 @@
1
+ import lsp from 'vscode-languageserver';
2
+ import type { CstNode } from 'chevrotain';
3
+ import type { SymbolTable } from '../java/symbol-table.js';
4
+ export interface SignatureChange {
5
+ /** New method name (or same if unchanged) */
6
+ newName?: string;
7
+ /** New parameter list. Use existing param names to keep, omit to remove, add new ones */
8
+ newParameters: {
9
+ type: string;
10
+ name: string;
11
+ }[];
12
+ /** New return type (or undefined to keep) */
13
+ newReturnType?: string;
14
+ }
15
+ /**
16
+ * Provide advanced refactoring code actions.
17
+ */
18
+ export declare function provideRefactoringActions(cst: CstNode, table: SymbolTable, text: string, uri: string, range: lsp.Range): lsp.CodeAction[];
19
+ /**
20
+ * Create a "Move Class" refactoring action.
21
+ * When triggered on a class declaration, generates edits to:
22
+ * 1. Update the package declaration in the source file
23
+ * 2. Update all import statements across workspace files that reference this class
24
+ */
25
+ export declare function createMoveClassAction(table: SymbolTable, text: string, uri: string, range: lsp.Range, newPackage: string, workspaceFiles?: Map<string, string>): lsp.CodeAction | null;
26
+ /**
27
+ * Create a "Change Method Signature" refactoring action.
28
+ * Updates the method declaration and all call sites across workspace.
29
+ */
30
+ export declare function createChangeSignatureAction(table: SymbolTable, text: string, uri: string, range: lsp.Range, change: SignatureChange, workspaceFiles?: Map<string, string>): lsp.CodeAction | null;
31
+ //# sourceMappingURL=refactoring.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"refactoring.d.ts","sourceRoot":"","sources":["../../src/features/refactoring.ts"],"names":[],"mappings":"AAQA,OAAO,GAAG,MAAM,uBAAuB,CAAC;AACxC,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,YAAY,CAAC;AAC1C,OAAO,KAAK,EAAE,WAAW,EAAc,MAAM,yBAAyB,CAAC;AAEvE,MAAM,WAAW,eAAe;IAC5B,6CAA6C;IAC7C,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,yFAAyF;IACzF,aAAa,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,EAAE,CAAC;IAChD,6CAA6C;IAC7C,aAAa,CAAC,EAAE,MAAM,CAAC;CAC1B;AAED;;GAEG;AACH,wBAAgB,yBAAyB,CACrC,GAAG,EAAE,OAAO,EACZ,KAAK,EAAE,WAAW,EAClB,IAAI,EAAE,MAAM,EACZ,GAAG,EAAE,MAAM,EACX,KAAK,EAAE,GAAG,CAAC,KAAK,GACjB,GAAG,CAAC,UAAU,EAAE,CAoBlB;AAqND;;;;;GAKG;AACH,wBAAgB,qBAAqB,CACjC,KAAK,EAAE,WAAW,EAClB,IAAI,EAAE,MAAM,EACZ,GAAG,EAAE,MAAM,EACX,KAAK,EAAE,GAAG,CAAC,KAAK,EAChB,UAAU,EAAE,MAAM,EAClB,cAAc,CAAC,EAAE,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,GACrC,GAAG,CAAC,UAAU,GAAG,IAAI,CAoFvB;AAMD;;;GAGG;AACH,wBAAgB,2BAA2B,CACvC,KAAK,EAAE,WAAW,EAClB,IAAI,EAAE,MAAM,EACZ,GAAG,EAAE,MAAM,EACX,KAAK,EAAE,GAAG,CAAC,KAAK,EAChB,MAAM,EAAE,eAAe,EACvB,cAAc,CAAC,EAAE,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,GACrC,GAAG,CAAC,UAAU,GAAG,IAAI,CA2FvB"}
@@ -0,0 +1,9 @@
1
+ import lsp from 'vscode-languageserver';
2
+ import type { CstNode } from 'chevrotain';
3
+ /**
4
+ * Compute selection ranges (smart expand/shrink) based on CST structure.
5
+ * For each position, returns a nested chain of ranges from most specific
6
+ * to full document.
7
+ */
8
+ export declare function provideSelectionRanges(cst: CstNode, _text: string, positions: lsp.Position[]): lsp.SelectionRange[];
9
+ //# sourceMappingURL=selection-range.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"selection-range.d.ts","sourceRoot":"","sources":["../../src/features/selection-range.ts"],"names":[],"mappings":"AAQA,OAAO,GAAG,MAAM,uBAAuB,CAAC;AACxC,OAAO,KAAK,EAAE,OAAO,EAAsB,MAAM,YAAY,CAAC;AAG9D;;;;GAIG;AACH,wBAAgB,sBAAsB,CAClC,GAAG,EAAE,OAAO,EACZ,KAAK,EAAE,MAAM,EACb,SAAS,EAAE,GAAG,CAAC,QAAQ,EAAE,GAC1B,GAAG,CAAC,cAAc,EAAE,CAEtB"}
@@ -0,0 +1,14 @@
1
+ import lsp from 'vscode-languageserver';
2
+ import type { CstNode } from 'chevrotain';
3
+ import type { SymbolTable } from '../java/symbol-table.js';
4
+ export interface SemanticDiagnostic {
5
+ range: lsp.Range;
6
+ message: string;
7
+ severity: lsp.DiagnosticSeverity;
8
+ code?: string;
9
+ }
10
+ /**
11
+ * Run all semantic checks and return diagnostics.
12
+ */
13
+ export declare function computeSemanticDiagnostics(cst: CstNode, table: SymbolTable, text: string): lsp.Diagnostic[];
14
+ //# sourceMappingURL=semantic-diagnostics.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"semantic-diagnostics.d.ts","sourceRoot":"","sources":["../../src/features/semantic-diagnostics.ts"],"names":[],"mappings":"AAQA,OAAO,GAAG,MAAM,uBAAuB,CAAC;AACxC,OAAO,KAAK,EAAE,OAAO,EAAsB,MAAM,YAAY,CAAC;AAC9D,OAAO,KAAK,EAAE,WAAW,EAAc,MAAM,yBAAyB,CAAC;AAevE,MAAM,WAAW,kBAAkB;IAC/B,KAAK,EAAE,GAAG,CAAC,KAAK,CAAC;IACjB,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,GAAG,CAAC,kBAAkB,CAAC;IACjC,IAAI,CAAC,EAAE,MAAM,CAAC;CACjB;AAED;;GAEG;AACH,wBAAgB,0BAA0B,CACtC,GAAG,EAAE,OAAO,EACZ,KAAK,EAAE,WAAW,EAClB,IAAI,EAAE,MAAM,GACb,GAAG,CAAC,UAAU,EAAE,CAclB"}
@@ -0,0 +1,12 @@
1
+ import lsp from 'vscode-languageserver';
2
+ import type { CstNode } from 'chevrotain';
3
+ import type { SymbolTable } from '../java/symbol-table.js';
4
+ export declare const SEMANTIC_TOKEN_TYPES: readonly ["namespace", "type", "class", "enum", "interface", "struct", "typeParameter", "parameter", "variable", "property", "enumMember", "function", "method", "keyword", "modifier", "comment", "string", "number", "operator", "decorator"];
5
+ export declare const SEMANTIC_TOKEN_MODIFIERS: readonly ["declaration", "definition", "readonly", "static", "deprecated", "abstract", "async", "modification", "documentation", "defaultLibrary"];
6
+ export declare function getSemanticTokensLegend(): lsp.SemanticTokensLegend;
7
+ /**
8
+ * Compute semantic tokens for a parsed Java file.
9
+ * When a SymbolTable is provided, identifiers are classified contextually.
10
+ */
11
+ export declare function computeSemanticTokens(cst: CstNode, table?: SymbolTable): lsp.SemanticTokens;
12
+ //# sourceMappingURL=semantic-tokens.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"semantic-tokens.d.ts","sourceRoot":"","sources":["../../src/features/semantic-tokens.ts"],"names":[],"mappings":"AAQA,OAAO,GAAG,MAAM,uBAAuB,CAAC;AACxC,OAAO,KAAK,EAAE,OAAO,EAAsB,MAAM,YAAY,CAAC;AAC9D,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAK3D,eAAO,MAAM,oBAAoB,iPAqBvB,CAAC;AAEX,eAAO,MAAM,wBAAwB,oJAW3B,CAAC;AAEX,wBAAgB,uBAAuB,IAAI,GAAG,CAAC,oBAAoB,CAKlE;AAED;;;GAGG;AACH,wBAAgB,qBAAqB,CAAC,GAAG,EAAE,OAAO,EAAE,KAAK,CAAC,EAAE,WAAW,GAAG,GAAG,CAAC,cAAc,CA2B3F"}
@@ -0,0 +1,7 @@
1
+ import lsp from 'vscode-languageserver';
2
+ import type { SymbolTable } from '../java/symbol-table.js';
3
+ /**
4
+ * Provide signature help when inside method call parentheses.
5
+ */
6
+ export declare function provideSignatureHelp(table: SymbolTable, text: string, line: number, character: number): lsp.SignatureHelp | null;
7
+ //# sourceMappingURL=signature-help.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"signature-help.d.ts","sourceRoot":"","sources":["../../src/features/signature-help.ts"],"names":[],"mappings":"AAQA,OAAO,GAAG,MAAM,uBAAuB,CAAC;AACxC,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAG3D;;GAEG;AACH,wBAAgB,oBAAoB,CAChC,KAAK,EAAE,WAAW,EAClB,IAAI,EAAE,MAAM,EACZ,IAAI,EAAE,MAAM,EACZ,SAAS,EAAE,MAAM,GAClB,GAAG,CAAC,aAAa,GAAG,IAAI,CAkD1B"}
@@ -0,0 +1,7 @@
1
+ import lsp from 'vscode-languageserver';
2
+ import type { SymbolTable } from '../java/symbol-table.js';
3
+ /**
4
+ * Provide source generation code actions for a class at the given range.
5
+ */
6
+ export declare function provideSourceGenerationActions(table: SymbolTable, text: string, range: lsp.Range, uri: string): lsp.CodeAction[];
7
+ //# sourceMappingURL=source-generation.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"source-generation.d.ts","sourceRoot":"","sources":["../../src/features/source-generation.ts"],"names":[],"mappings":"AAQA,OAAO,GAAG,MAAM,uBAAuB,CAAC;AACxC,OAAO,KAAK,EAAE,WAAW,EAAc,MAAM,yBAAyB,CAAC;AAEvE;;GAEG;AACH,wBAAgB,8BAA8B,CAC1C,KAAK,EAAE,WAAW,EAClB,IAAI,EAAE,MAAM,EACZ,KAAK,EAAE,GAAG,CAAC,KAAK,EAChB,GAAG,EAAE,MAAM,GACZ,GAAG,CAAC,UAAU,EAAE,CAyGlB"}
@@ -0,0 +1,6 @@
1
+ import type { CstNode, IToken } from 'chevrotain';
2
+ /**
3
+ * Find the token at a given 0-based line and character position.
4
+ */
5
+ export declare function getTokenAtPosition(cst: CstNode, line: number, character: number): IToken | undefined;
6
+ //# sourceMappingURL=token-utils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"token-utils.d.ts","sourceRoot":"","sources":["../../src/features/token-utils.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,OAAO,EAAc,MAAM,EAAE,MAAM,YAAY,CAAC;AAG9D;;GAEG;AACH,wBAAgB,kBAAkB,CAAC,GAAG,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,CAqBpG"}
@@ -0,0 +1,7 @@
1
+ import lsp from 'vscode-languageserver';
2
+ import type { SymbolTable } from '../java/symbol-table.js';
3
+ import type { WorkspaceIndex } from '../project/workspace-index.js';
4
+ export declare function prepareTypeHierarchy(table: SymbolTable, uri: string, line: number, _character: number): lsp.TypeHierarchyItem[] | null;
5
+ export declare function provideSupertypes(table: SymbolTable, uri: string, item: lsp.TypeHierarchyItem, workspaceIndex?: WorkspaceIndex): lsp.TypeHierarchyItem[];
6
+ export declare function provideSubtypes(table: SymbolTable, uri: string, item: lsp.TypeHierarchyItem, workspaceIndex?: WorkspaceIndex): lsp.TypeHierarchyItem[];
7
+ //# sourceMappingURL=type-hierarchy.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"type-hierarchy.d.ts","sourceRoot":"","sources":["../../src/features/type-hierarchy.ts"],"names":[],"mappings":"AAQA,OAAO,GAAG,MAAM,uBAAuB,CAAC;AACxC,OAAO,KAAK,EAAE,WAAW,EAAc,MAAM,yBAAyB,CAAC;AACvE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,+BAA+B,CAAC;AAQpE,wBAAgB,oBAAoB,CAChC,KAAK,EAAE,WAAW,EAClB,GAAG,EAAE,MAAM,EACX,IAAI,EAAE,MAAM,EACZ,UAAU,EAAE,MAAM,GACnB,GAAG,CAAC,iBAAiB,EAAE,GAAG,IAAI,CAiBhC;AAED,wBAAgB,iBAAiB,CAC7B,KAAK,EAAE,WAAW,EAClB,GAAG,EAAE,MAAM,EACX,IAAI,EAAE,GAAG,CAAC,iBAAiB,EAC3B,cAAc,CAAC,EAAE,cAAc,GAChC,GAAG,CAAC,iBAAiB,EAAE,CAyBzB;AAED,wBAAgB,eAAe,CAC3B,KAAK,EAAE,WAAW,EAClB,GAAG,EAAE,MAAM,EACX,IAAI,EAAE,GAAG,CAAC,iBAAiB,EAC3B,cAAc,CAAC,EAAE,cAAc,GAChC,GAAG,CAAC,iBAAiB,EAAE,CAgBzB"}
@@ -0,0 +1,57 @@
1
+ import type { CstNode } from 'chevrotain';
2
+ import type { JavaSymbol } from './symbol-table.js';
3
+ export interface AnnotationInfo {
4
+ /** Simple name, e.g. "Data" */
5
+ name: string;
6
+ /** Fully-qualified name, e.g. "lombok.Data" */
7
+ qualifiedName?: string;
8
+ /** What kind of element the annotation was found on */
9
+ target: 'class' | 'field' | 'method' | 'parameter';
10
+ }
11
+ export interface GeneratedSymbol {
12
+ name: string;
13
+ kind: JavaSymbol['kind'];
14
+ type?: string;
15
+ modifiers: string[];
16
+ parameters?: {
17
+ name: string;
18
+ type: string;
19
+ }[];
20
+ isGenerated: true;
21
+ generatedBy: string;
22
+ }
23
+ /**
24
+ * Extract annotations from a class / field / method CST node by inspecting
25
+ * its modifier children.
26
+ */
27
+ export declare function extractAnnotations(node: CstNode): AnnotationInfo[];
28
+ /**
29
+ * Generate virtual symbols for a class based on its Lombok annotations.
30
+ *
31
+ * The caller controls scope by which `fields` are passed in:
32
+ * - Class-level annotation → pass all class fields
33
+ * - Field-level annotation → pass only the annotated field
34
+ */
35
+ export declare function processAnnotations(classSymbol: JavaSymbol, annotations: AnnotationInfo[], fields: JavaSymbol[]): GeneratedSymbol[];
36
+ /**
37
+ * Check if any of the given annotations mark the class as a Spring bean.
38
+ */
39
+ export declare function isSpringBean(annotations: AnnotationInfo[]): boolean;
40
+ /**
41
+ * If the annotations include a Spring endpoint mapping, return the HTTP
42
+ * method (or `null` if the annotations do not describe an endpoint).
43
+ */
44
+ export declare function isSpringEndpoint(annotations: AnnotationInfo[]): {
45
+ method: string;
46
+ path?: string;
47
+ } | null;
48
+ /**
49
+ * Return Spring endpoint info (HTTP method + path) when the annotations
50
+ * describe an endpoint. Path defaults to `""` since annotation values
51
+ * are not parsed from the CST.
52
+ */
53
+ export declare function getSpringEndpointInfo(annotations: AnnotationInfo[]): {
54
+ httpMethod: string;
55
+ path: string;
56
+ } | null;
57
+ //# sourceMappingURL=annotation-processor.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file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H,wBAAgB,qBAAqB,CACjC,WAAW,EAAE,cAAc,EAAE,GAC9B;IAAE,UAAU,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAA;CAAE,GAAG,IAAI,CAQ7C"}
@@ -0,0 +1,57 @@
1
+ export interface ClassFileInfo {
2
+ className: string;
3
+ simpleName: string;
4
+ packageName: string;
5
+ superClassName?: string;
6
+ interfaces: string[];
7
+ accessFlags: number;
8
+ isPublic: boolean;
9
+ isAbstract: boolean;
10
+ isInterface: boolean;
11
+ isEnum: boolean;
12
+ isAnnotation: boolean;
13
+ fields: ClassFieldInfo[];
14
+ methods: ClassMethodInfo[];
15
+ majorVersion: number;
16
+ }
17
+ export interface ClassFieldInfo {
18
+ name: string;
19
+ type: string;
20
+ descriptor: string;
21
+ isPublic: boolean;
22
+ isStatic: boolean;
23
+ isFinal: boolean;
24
+ }
25
+ export interface ClassMethodInfo {
26
+ name: string;
27
+ returnType: string;
28
+ parameterTypes: string[];
29
+ descriptor: string;
30
+ isPublic: boolean;
31
+ isStatic: boolean;
32
+ isAbstract: boolean;
33
+ isSynthetic: boolean;
34
+ }
35
+ /**
36
+ * Parse a JVM method descriptor into human-readable parameter and return types.
37
+ *
38
+ * Example: `(Ljava/lang/String;I)V` → `{ parameterTypes: ['String', 'int'], returnType: 'void' }`
39
+ */
40
+ export declare function parseMethodDescriptor(descriptor: string): {
41
+ parameterTypes: string[];
42
+ returnType: string;
43
+ };
44
+ /**
45
+ * Convert a JVM field descriptor to a human-readable type string.
46
+ *
47
+ * Example: `Ljava/lang/String;` → `String`, `[I` → `int[]`
48
+ */
49
+ export declare function parseFieldDescriptor(descriptor: string): string;
50
+ /**
51
+ * Parse a Java `.class` file buffer and extract type metadata.
52
+ *
53
+ * Returns `null` if the buffer is not a valid class file (wrong magic number
54
+ * or truncated data). This function does **not** require a JVM.
55
+ */
56
+ export declare function readClassFile(buffer: Buffer): ClassFileInfo | null;
57
+ //# sourceMappingURL=class-file-reader.d.ts.map
@@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AAgB,oBAAoB,CAAC,UAAU,EAAE,MAAM,GAAG,MAAM,CAG/D;AAmLD;;;;;GAKG;AACH,wBAAgB,aAAa,CAAC,MAAM,EAAE,MAAM,GAAG,aAAa,GAAG,IAAI,CA8DlE"}
@@ -0,0 +1,33 @@
1
+ import type { CstNode, CstElement, IToken } from 'chevrotain';
2
+ /**
3
+ * Check if a CstElement is a CstNode (has children) vs an IToken (leaf).
4
+ */
5
+ export declare function isCstNode(element: CstElement): element is CstNode;
6
+ /**
7
+ * Get the start position (line, column) of a CST element.
8
+ * Lines and columns are 1-based (as provided by Chevrotain).
9
+ */
10
+ export declare function getStartPosition(element: CstElement): {
11
+ line: number;
12
+ column: number;
13
+ };
14
+ /**
15
+ * Get the end position (line, column) of a CST element.
16
+ */
17
+ export declare function getEndPosition(element: CstElement): {
18
+ line: number;
19
+ column: number;
20
+ };
21
+ /**
22
+ * Recursively find the first token in a CST node.
23
+ */
24
+ export declare function findFirstToken(node: CstNode): IToken | undefined;
25
+ /**
26
+ * Recursively find the last token in a CST node.
27
+ */
28
+ export declare function findLastToken(node: CstNode): IToken | undefined;
29
+ /**
30
+ * Collect all tokens in a CST node in order of appearance.
31
+ */
32
+ export declare function collectTokens(node: CstNode): IToken[];
33
+ //# sourceMappingURL=cst-utils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cst-utils.d.ts","sourceRoot":"","sources":["../../src/java/cst-utils.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,OAAO,EAAE,UAAU,EAAE,MAAM,EAAE,MAAM,YAAY,CAAC;AAE9D;;GAEG;AACH,wBAAgB,SAAS,CAAC,OAAO,EAAE,UAAU,GAAG,OAAO,IAAI,OAAO,CAEjE;AAED;;;GAGG;AACH,wBAAgB,gBAAgB,CAAC,OAAO,EAAE,UAAU,GAAG;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,MAAM,CAAA;CAAE,CAUtF;AAED;;GAEG;AACH,wBAAgB,cAAc,CAAC,OAAO,EAAE,UAAU,GAAG;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,MAAM,CAAA;CAAE,CAUpF;AAED;;GAEG;AACH,wBAAgB,cAAc,CAAC,IAAI,EAAE,OAAO,GAAG,MAAM,GAAG,SAAS,CAahE;AAED;;GAEG;AACH,wBAAgB,aAAa,CAAC,IAAI,EAAE,OAAO,GAAG,MAAM,GAAG,SAAS,CAgB/D;AAED;;GAEG;AACH,wBAAgB,aAAa,CAAC,IAAI,EAAE,OAAO,GAAG,MAAM,EAAE,CAKrD"}
@@ -0,0 +1,24 @@
1
+ import type { CstNode } from 'chevrotain';
2
+ import type { SymbolTable } from './symbol-table.js';
3
+ import type { WorkspaceIndex } from '../project/workspace-index.js';
4
+ export interface ExpressionTypeContext {
5
+ symbolTable: SymbolTable;
6
+ workspaceIndex?: WorkspaceIndex;
7
+ /** Current position for scope resolution (0-based) */
8
+ line: number;
9
+ /** Current position for scope resolution (0-based) */
10
+ column: number;
11
+ /** The enclosing class name (for `this` resolution) */
12
+ enclosingClassName?: string;
13
+ }
14
+ /**
15
+ * Resolve the type of a CST expression node.
16
+ * Returns the type name string (e.g., "String", "int", "List<Pet>") or undefined.
17
+ */
18
+ export declare function resolveExpressionType(exprNode: CstNode, context: ExpressionTypeContext): string | undefined;
19
+ /**
20
+ * Resolve the type of an identifier at a position by checking scope.
21
+ * Checks: local variables, parameters, fields, class names.
22
+ */
23
+ export declare function resolveIdentifierType(name: string, context: ExpressionTypeContext): string | undefined;
24
+ //# sourceMappingURL=expression-type-resolver.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"expression-type-resolver.d.ts","sourceRoot":"","sources":["../../src/java/expression-type-resolver.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,OAAO,EAAU,MAAM,YAAY,CAAC;AAClD,OAAO,KAAK,EAAc,WAAW,EAAE,MAAM,mBAAmB,CAAC;AACjE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,+BAA+B,CAAC;AAIpE,MAAM,WAAW,qBAAqB;IAClC,WAAW,EAAE,WAAW,CAAC;IACzB,cAAc,CAAC,EAAE,cAAc,CAAC;IAChC,sDAAsD;IACtD,IAAI,EAAE,MAAM,CAAC;IACb,sDAAsD;IACtD,MAAM,EAAE,MAAM,CAAC;IACf,uDAAuD;IACvD,kBAAkB,CAAC,EAAE,MAAM,CAAC;CAC/B;AA8BD;;;GAGG;AACH,wBAAgB,qBAAqB,CACjC,QAAQ,EAAE,OAAO,EACjB,OAAO,EAAE,qBAAqB,GAC/B,MAAM,GAAG,SAAS,CAwBpB;AAED;;;GAGG;AACH,wBAAgB,qBAAqB,CACjC,IAAI,EAAE,MAAM,EACZ,OAAO,EAAE,qBAAqB,GAC/B,MAAM,GAAG,SAAS,CA+BpB"}