Bug 28208

Summary: IClasspathEntry.getExclusionPattern: String[] would be better
Product: [Eclipse Project] JDT Reporter: Martin Aeschlimann <martinae>
Component: CoreAssignee: Philipe Mulet <philippe_mulet>
Status: RESOLVED WONTFIX QA Contact:
Severity: normal    
Priority: P3    
Version: 2.1   
Target Milestone: 2.1 M4   
Hardware: PC   
OS: Windows 2000   
Whiteboard:

Description Martin Aeschlimann CLA 2002-12-12 14:52:35 EST
20021212

IClasspathEntry.getExclusionPattern returns a IPath[] to describe the exclusion 
patterns.
Even the format of the pattern looks like a path, it isn't. Special 
characters '*', '?' '**' can be contained.
The pattern makes a difference between ending with a slash and without. Paths 
don't (new Path("src").equals(new Path("src/")).

For these reasons I would think it would be better to use String instead of 
IPath
Comment 1 Philipe Mulet CLA 2002-12-12 17:23:13 EST
Exclusion patterns are inherently paths. IPath remembers a trailing separator, 
the #equals doesn't care, this is another issue which should be debated with 
IPath providers.

Also IPaths provide support for adding segments, trimming and sanity check (no 
contiguous separators).

We won't change this just because the equals implementation doesn't meet your 
expectation.
Comment 2 Philipe Mulet CLA 2002-12-13 06:38:08 EST
Closing