Summary: | Request to make the AllTypesCache public | ||
---|---|---|---|
Product: | [Eclipse Project] JDT | Reporter: | Channing Walton <channingwalton> |
Component: | Core | Assignee: | Jerome Lanneluc <jerome_lanneluc> |
Status: | RESOLVED WONTFIX | QA Contact: | |
Severity: | enhancement | ||
Priority: | P3 | ||
Version: | 3.1 | ||
Target Milestone: | 3.1 M6 | ||
Hardware: | All | ||
OS: | All | ||
Whiteboard: |
Description
Channing Walton
2005-03-04 11:01:54 EST
The AllTypesCache is an unbounded cache which doesn't scale well. This is why we are reconsidering this part of the problem, but it will not be surfaced as is. One thing that would help is to understand you usecase. Why are you trying to match anything in editor using it ? Feels to me that the DOM AST API is something which could help you quite a bit here; as it carries resolved information about all referenced type. Hi, my editor is a wiki editor (eclipsewiki.sourceforge.net) which supports links to Java types. Any text matching a fully qualified type name in the same project as the wiki document is highlighted. So as the user is typing, the editor's scanner is checking for types matching the text at the current cursor position. For large projects this becomes very expensive unless I use the AllTypesCache. Channing Jerome - pls point Channing at suitable existing APIs (codeselect, dom ast, ...) Channing, you should use the DOM AST (see org.eclipse.jdt.core.dom.ASTParser) to have resolved information (using ASTParser.setResolveBindings(true)). If you want to know if a type (an ITypeBinding) is part of the same project, you can use #getJavaElement() on this type and #getJavaProject() on the returned Java element. OK to close ? Thanks, I'll have a look at this. OK to close. Channing Closing |