This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 53390 - When freeform project classpath is edited via properties view it destroys paths containing properties
Summary: When freeform project classpath is edited via properties view it destroys pat...
Status: RESOLVED DUPLICATE of bug 50409
Alias: None
Product: java
Classification: Unclassified
Component: Freeform (show other bugs)
Version: 4.x
Hardware: All All
: P4 blocker (vote)
Assignee: jrojcek
URL:
Keywords: UI
Depends on:
Blocks:
 
Reported: 2005-01-13 23:26 UTC by bwl
Modified: 2005-09-05 10:01 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description bwl 2005-01-13 23:26:57 UTC
This fault found with the NB4.1 Xmas build.

1) Take a FreeForm project with a classpath
containing properties.  e.g.:
        <java-data
xmlns="http://www.netbeans.org/ns/freeform-project-java/1">
            <compilation-unit>
                <package-root>src</package-root>
                <package-root>test</package-root>
                <classpath
mode="compile">${dist.dir}/adc-debug.jar:${dist.dir}/adc-license.jar:${dist.dir}/adc-profiler.jar:${dist.dir}/adc-schema.jar:${dist.dir}/adc-util.jar:${dist.dir}/conflib.jar:${dist.dir}/adc-connect6.jar:${eji.v600.dir}/eji.jar:${tools.dir}/junit/junit.jar:${tools.dir}/jakarta-ant/lib/ant.jar:${tools.dir}/dom4j/dom4j.jar</classpath>
               
<built-to>${build.dir}/docobj</built-to>
               
<built-to>${test.dir}/docobj</built-to>
                <source-level>1.4</source-level>
            </compilation-unit>
        </java-data>
2) Open the project properties in NetBeans,
navigate to the Classpath panel, and use "Add
JAR/Folder" to add a new Jar file.  Project now
contains:
            <compilation-unit>^M
                <package-root>src</package-root>^M
                <package-root>test</package-root>^M
                <classpath
mode="compile">E:\cttrunk\dist\adc-debug.jar;E:\cttrunk\dist\adc-license.jar;E:\cttrunk\dist\adc-profiler.jar;E:\cttrunk\dist\adc-schema.jar;E:\cttrunk\dist\adc-util.jar;E:\cttrunk\dist\conflib.jar;E:\cttrunk\dist\adc-connect6.jar;E:\ctapp\cb\product\6.00.00\java\lib\eji.jar;C:\javadev\tools\junit\junit.jar;C:\javadev\tools\jakarta-ant\lib\ant.jar;C:\javadev\tools\dom4j\dom4j.jar;E:\cttrunk\javadev\tools\checkstyle\jakarta-regexp-1.2.jar</classpath>^M
               
<built-to>${build.dir}/docobj</built-to>^M
               
<built-to>${test.dir}/docobj</built-to>^M
                <source-level>1.4</source-level>^M
            </compilation-unit>^M

i.e. it has replaced all the property values.  I
would not expect it to alter the entries for the
existing classpath elements. 

The same thing seems to happen if you delete an
existing classpath element.

As an aside, it would be helpful if the Classpath
display in the project properties dialog gave some
indication that the classpath elements contain
property values.  (And even better if you could
actually edit the classpath entries to contain
property values).
Comment 1 Jesse Glick 2005-01-14 18:51:03 UTC
If you have a hand-edited freeform project.xml, avoid using the GUI
customizer for the areas you have edited by hand. Generally the GUI
customizer (intentionally) supports only a subset of the capabilities
of the project.xml syntax.
Comment 2 bwl 2005-01-16 23:02:28 UTC
I appreciate that, but in this case it seems to me that the GUI
customizer is altering path elements that the user hasn't asked it to
do anything to.  Also, in a team situation it is highly unlikely that
all team members would be aware of the detail of the implementation of
a freeform project (i.e. that some parts can only be edited
successfully by hand) - so it would be helpful if the customizer in
some way indicated it to them.  Maybe the classpath customizer should
simply be disabled if the classpath contains any property values?
Comment 3 David Konecny 2005-01-24 13:46:24 UTC
Tomas, moving java project specific issues to you for now.
Comment 4 Tomas Zezula 2005-04-05 15:44:06 UTC
Jano, what do you tkink about it? It is possible to design a UI to at least mark
the classpath roots which contain properties. I am not sure by editing, UI for
editing classpath root containing property will be probably very ugly.
Comment 5 Tomas Zezula 2005-04-11 13:57:42 UTC
Should be addressed in the NetBeans 4.2. There are several complains about it.
Comment 6 Jesse Glick 2005-05-06 19:15:20 UTC

*** This issue has been marked as a duplicate of 50409 ***