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 42480 - Misc. reorganizations in Project API
Summary: Misc. reorganizations in Project API
Status: RESOLVED FIXED
Alias: None
Product: projects
Classification: Unclassified
Component: Generic Infrastructure (show other bugs)
Version: 4.x
Hardware: All All
: P1 blocker (vote)
Assignee: Jesse Glick
URL:
Keywords: API
Depends on:
Blocks: 41535
  Show dependency tree
 
Reported: 2004-04-26 17:44 UTC by Jesse Glick
Modified: 2004-08-13 12:11 UTC (History)
3 users (show)

See Also:
Issue Type: TASK
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jesse Glick 2004-04-26 17:44:43 UTC
I would like to make some changes in some APIs in
projects/projectapi for the following reasons:

1. Reduced likelihood that an API client would
need to import a class from the SPI.

2. Better evolvability of interfaces - it is
generally not safe for clients to directly look
for things in Project.lookup. (OK to keep the same
interface for API and SPI since it is possible to
introduce new interfaces for API and/or SPI in the
future and proxy both ways.)

3. Better event firing support is definitely
needed in some cases and may plausibly be needed
in others later (use cases under consideration);
easiest to add the API now. In some cases (SPP)
the actual firing code could be deferred until
some client tries to listen.

Proposed changes:

1. Move ProjectInformation and Sources and
SourceGroup to the API package, since these can be
of interest to API clients.

2. Add a method to ProjectUtils to get a Sources
object for a Project - should check Project.lookup
and fall back to SourceContainers.genericOnly.

3. Add some kind of event firing capabilities to
Sources and SourceGroup.

4. [Maybe] Add 'icon' and (code) 'name' properties
to SourceGroup to make it easier to list a bunch
of source groups as nodes, e.g. in the Files tab.

5. Fix the name SourceContainers which is obsolete.

6. [Maybe] Permit changes to be fired from
SubprojectProvider.

Would of course involve adjusting all stable
netbeans.org modules to use the new APIs.
Comment 1 Jesse Glick 2004-04-26 20:28:49 UTC
Change #5 done by issue #40964.
Comment 2 Jesse Glick 2004-04-30 02:11:25 UTC
Also:

- moving Sources.TYPE_JAVA and Artifact.TYPE_JAR to a new interface
JavaProjectConstants to avoid polluting the general API with
Java-specific items
Comment 3 Jesse Glick 2004-04-30 05:23:00 UTC
committed 1.6 
ant/project/src/org/netbeans/api/project/ant/AntArtifact.java
committed 1.5 
ant/project/src/org/netbeans/spi/project/support/ant/SourcesHelper.java
committed 1.4 
ant/project/src/org/netbeans/spi/project/support/ant/SubprojectProviderImpl.java
committed 1.8 
ant/project/test/unit/src/org/netbeans/spi/project/support/ant/AntBasedTestUtil.java
committed 1.4 
ant/project/test/unit/src/org/netbeans/spi/project/support/ant/ProjectGeneratorTest.java
committed 1.3 
ant/project/test/unit/src/org/netbeans/spi/project/support/ant/SourcesHelperTest.java
committed 1.11
apisupport/project/src/org/netbeans/modules/apisupport/project/LogicalView.java
committed 1.38
apisupport/project/src/org/netbeans/modules/apisupport/project/NbModuleProject.java
committed 1.6 
apisupport/project/src/org/netbeans/modules/apisupport/project/SubprojectProviderImpl.java
committed 1.13
java/j2seproject/src/org/netbeans/modules/java/j2seproject/J2SEProject.java
committed 1.9 
java/j2seproject/src/org/netbeans/modules/java/j2seproject/ui/customizer/J2SEProjectProperties.java
committed 1.4 
java/j2seproject/src/org/netbeans/modules/java/j2seproject/ui/customizer/VisualClasspathSupport.java
added     1.1 
java/project/src/org/netbeans/api/java/project/JavaProjectConstants.java
committed 1.4 
java/project/src/org/netbeans/modules/java/project/JavaTargetChooserPanel.java
committed 1.5 
java/project/src/org/netbeans/modules/java/project/JavaTargetChooserPanelGUI.java
committed 1.3 
java/project/src/org/netbeans/modules/java/project/NewJavaFileWizardIterator.java
committed 1.5 
java/project/src/org/netbeans/spi/java/project/support/ui/templates/JavaTemplates.java
added     1.1 
projects/projectapi/src/org/netbeans/api/project/ProjectInformation.java
committed 1.2 
projects/projectapi/src/org/netbeans/api/project/ProjectUtils.java
added     1.1 
projects/projectapi/src/org/netbeans/api/project/SourceGroup.java
added     1.1 
projects/projectapi/src/org/netbeans/api/project/Sources.java
removed   1.2 
projects/projectapi/src/org/netbeans/spi/project/ProjectInformation.java
removed   1.3 
projects/projectapi/src/org/netbeans/spi/project/SourceGroup.java
removed   1.3 
projects/projectapi/src/org/netbeans/spi/project/Sources.java
committed 1.3 
projects/projectapi/src/org/netbeans/spi/project/SubprojectProvider.java
committed 1.3 
projects/projectapi/src/org/netbeans/spi/project/support/GenericSources.java
committed 1.2 
projects/projectui/src/org/netbeans/modules/project/ui/BrowseFolders.java
committed 1.5 
projects/projectui/src/org/netbeans/modules/project/ui/NewFileWizard.java
committed 1.7 
projects/projectui/src/org/netbeans/modules/project/ui/PhysicalViewFactoryImpl.java
committed 1.5 
projects/projectui/src/org/netbeans/modules/project/ui/ProjectChooserFactoryImpl.java
committed 1.4 
projects/projectui/src/org/netbeans/modules/project/ui/SimpleTargetChooserPanel.java
committed 1.10
projects/projectui/src/org/netbeans/modules/project/ui/SimpleTargetChooserPanelGUI.java
committed 1.3 
projects/projectui/src/org/netbeans/modules/project/ui/TemplateChooserPanel.java
committed 1.6 
projects/projectui/src/org/netbeans/modules/project/ui/TemplateChooserPanelGUI.java
committed 1.2 
projects/projectui/src/org/netbeans/modules/project/ui/actions/RecentProjects.java
committed 1.2 
projects/projectui/src/org/netbeans/modules/project/ui/actions/SetMainProject.java
committed 1.4 
projects/projectuiapi/src/org/netbeans/modules/project/uiapi/ProjectChooserFactory.java
committed 1.7 
projects/projectuiapi/src/org/netbeans/spi/project/ui/templates/support/Templates.java
committed 1.90
tasklist/docscan/src/org/netbeans/modules/tasklist/docscan/SourceTasksView.java
committed 1.4 
web/core/src/org/netbeans/modules/web/dd/wizards/PageIterator.java
committed 1.11
web/project/src/org/netbeans/modules/web/project/WebProject.java
committed 1.4 
web/project/src/org/netbeans/modules/web/project/WebSources.java
committed 1.7 
web/project/src/org/netbeans/modules/web/project/ui/customizer/VisualClasspathSupport.java