Summary: | [search][doc] Java search tab documentation is confusing about qualified name | ||
---|---|---|---|
Product: | [Eclipse Project] JDT | Reporter: | Gabrio Verratti <gabrioverratti> |
Component: | Core | Assignee: | Frederic Fusier <frederic_fusier> |
Status: | VERIFIED FIXED | QA Contact: | |
Severity: | trivial | ||
Priority: | P3 | ||
Version: | 3.0 | ||
Target Milestone: | 3.1 RC1 | ||
Hardware: | PC | ||
OS: | Windows XP | ||
Whiteboard: |
Description
Gabrio Verratti
2004-09-14 17:04:26 EDT
I suspect it was talking about finding references to a specific field, not its declaration. If you search for references to a field 'foo' you could find many more references than 'p1.A.foo'. Unfortunately, I agree that documentation is a little bit confusing here. It's absolutely not mandatory to specify the fully qualified name to be able to find a field. Same thing for types, methods and constructors. It should write for field: "the field name and eventually the fully qualified name of the defining type (eg. name or org.eclipse.jdt.internal.core.JavaElement.name)" The difference is in the fact that if you do not specify the fully qualified name, you could get several different matches. Imagine you're looking for field "foo" declaration and your project contains 2 classes X and Y both defining a field foo. The result of your search without qualified named will report the two declarations although a fully qualified one would report only one or zero (if the qualification matches neither X nor Y)... But this for search from Java Search tab in Search dialog. If you use the search from popup-menu directly from Hierarchy or Outline views, Editor, or Package Explorer, then you won't have any question about the search. It will work automatically :-) Just select the element you want to search (field in your example) and select Search->Declarations->Workspace in popup-menu and you'll see it appearing in Search View without having specified the fully qualified name... Fixed and released in HEAD. Also added examples to show qualified and non-qualified strings... Verified in I20050526-2000 |