Bug 80098 - newTypeHierarchy(IRegion,...) should not be constrained to an IJavaProject
Summary: newTypeHierarchy(IRegion,...) should not be constrained to an IJavaProject
Status: VERIFIED FIXED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 3.1   Edit
Hardware: PC Windows XP
: P3 enhancement (vote)
Target Milestone: 3.1 M5   Edit
Assignee: Jerome Lanneluc CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-12-03 08:41 EST by Markus Keller CLA
Modified: 2005-02-15 07:50 EST (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Markus Keller CLA 2004-12-03 08:41:26 EST
As Dirk has discussed with Philippe and Jerome, we need API to build a
supertypes hierarchy on an arbitrary IRegion that crosses project boundaries.
This API is required for the new implementation of the RippleMethodFinder.

Currently, IJavaProject has methods 
    newTypeHierarchy(IRegion, IProgressMonitor)
    newTypeHierarchy(IRegion, WorkingCopyOwner, IProgressMonitor)
, whose Javadocs promise exactly that. The only sore point is that these methods
have to be called on an IJavaProject, and it is not clear to me what the role of
the receiver project is.

If the methods don't depend on the receiver project, then the methods should be
moved to JavaCore. If they do depend, then
- that dependency should be explained in the methods' Javadocs, and
- we request new methods on JavaCore which build the supertypes hierarchy on
types from an arbitrary IRegion.
Comment 1 Jerome Lanneluc CLA 2005-01-13 05:11:53 EST
Added JavaCore#newTypeHierarchy(IRegion, WorkingCopyOwner, IProgressMonitor)
that creates a type hierarchy on a region independantly from a project. Note
that old APIs must remain for backward compatibility.

Added test TypeHierarchyTests#testRegion4
Comment 2 David Audel CLA 2005-02-15 07:50:13 EST
Verified in I20050214-0927