Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 349339

Summary: [project setup] JSWebResourceEventManager needs to check that the Source entry it creates does not conflict with an existing entry
Product: [WebTools] JSDT Reporter: Chris Jaun <cmjaun>
Component: WebAssignee: Chris Jaun <cmjaun>
Status: RESOLVED FIXED QA Contact: Nitin Dahyabhai <thatnitind>
Severity: normal    
Priority: P3 Flags: thatnitind: review+
Version: 3.2.5   
Target Milestone: 3.2.5   
Hardware: PC   
OS: Windows XP   
Whiteboard:
Attachments:
Description Flags
patch
none
new patch none

Description Chris Jaun CLA 2011-06-14 11:46:45 EDT
JSWebResourceEventManager takes a "dummy" source entry and converts it to the correct source entry after the web module nature has been installed.

However, it is possible that there is an existing library entry that matches the new source path. In this case we do not want to create a conflict, so check if the entry paths match and if they do there is no reason to create the source entry.
Comment 1 Chris Jaun CLA 2011-06-14 11:47:29 EDT
Created attachment 197962 [details]
patch
Comment 2 Nitin Dahyabhai CLA 2011-06-14 15:25:40 EDT
Actually, does it matter if one of the resolved entries matching a root path is IIncludePathEntry.CPE_LIBRARY and not some other kind of entry?
Comment 3 Chris Jaun CLA 2011-06-14 17:25:10 EDT
Created attachment 197984 [details]
new patch

It does not....updated patch.
Comment 4 Chris Jaun CLA 2011-06-15 10:08:32 EDT
Checked into HEAD and 3.2.5.
Comment 5 Chris Jaun CLA 2011-06-20 11:11:56 EDT
Minor update made to for loop to change <= to <.