Bug 25933 - After adding a parent folder, no longer able to add sub folder to classpath.
Summary: After adding a parent folder, no longer able to add sub folder to classpath.
Status: VERIFIED FIXED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Debug (show other bugs)
Version: 2.1   Edit
Hardware: PC Windows 2000
: P2 normal (vote)
Target Milestone: 2.1 M4   Edit
Assignee: Joe Szurszewski CLA
QA Contact:
URL:
Whiteboard:
Keywords:
: 25934 (view as bug list)
Depends on:
Blocks:
 
Reported: 2002-11-08 19:29 EST by IH CLA
Modified: 2002-12-09 16:56 EST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description IH CLA 2002-11-08 19:29:38 EST
Under project, run, then classpath tab.  From the userclasses subtab, Unselect
use default class path and click advanced.  Use the Add folders radiobox and
select a folder that has subfolders.  Now add another except this time try to
add a sub folder of the folder you just added.  The folder you just added no
longer appears in this list making this impossible.  Workaround is to first add
the sub folder then add the parent folder.
Comment 1 Sonia Dimitrov CLA 2002-11-11 10:19:55 EST
*** Bug 25934 has been marked as a duplicate of this bug. ***
Comment 2 Martin Aeschlimann CLA 2002-11-12 06:09:15 EST
In the JDT-UI build path dialog that's the indended behaviour as this would 
result in a nesting conflict.
DOn't know if this restriction also applies to the launching classpath.
Comment 3 Darin Wright CLA 2002-11-14 15:26:47 EST
Yes - this is the intention. A subfolder cannot be added as it implies an 
overlapping set of package fragment roots, which is not allowed. However, we 
did not account for the reverse scenario - i.e. adding a subfolder followed by 
a parent.

The question is, should enfore this restriction? Needs investigation.
Comment 4 IH CLA 2002-11-15 21:13:19 EST
Alright well let me give you my scenario to make it a little more clear why I 
would do this.  I have a directory called config.  This directory has 
log4j.properties and other property files which must be in the path.  Now 
sometimes I run my app in debug mode in which case the production 
log4j.properties which is in the config directory is unsuitable, however, the 
rest of the config files in that directory are still suitable.  So what I do is 
I want a standalone log4j.properties file in the path before the config one.  I 
created a standalone dir under the config dir like /config/standalone.  Now to 
make this work on my debug apps I put this in the classpath 
first /config/standalone;/config such that the log4j of the standalone is found 
first.  

When I read your messages it seems you only consider classes in the classpath 
whereas the classpath holds both classes and in this case property files.
Comment 5 Darin Wright CLA 2002-12-06 12:59:23 EST
It appears that running from "java" from the command line supports this, so 
there is no reason why we should have this restriction. 
Comment 6 Darin Wright CLA 2002-12-06 13:24:25 EST
Fixed. Adding subfolders is now allowed.
Comment 7 Darin Wright CLA 2002-12-06 13:24:41 EST
Please verify, Joe S.
Comment 8 Joe Szurszewski CLA 2002-12-09 16:56:38 EST
Verified.