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 45058

Summary: Ability to listen to GlobalPathRegistry.sourceRoots
Product: java Reporter: Jesse Glick <jglick>
Component: ClasspathAssignee: Tomas Zezula <tzezula>
Status: NEW ---    
Severity: blocker Keywords: API
Priority: P3    
Version: 4.x   
Hardware: All   
OS: All   
Issue Type: ENHANCEMENT Exception Reporter:
Bug Depends on:    
Bug Blocks: 41535    

Description Jesse Glick 2004-06-16 19:55:21 UTC
Possible API enhancement: deprecate GPR.sR and
GPR.findResource; introduce into GPR

public ClassPath getRelevantSources();
public ClassPath getRelevantJavadoc();

where gRS would work similarly to the current sR -
i.e. start with all CP.SOURCE, and add all SFBQ
translations of CP.COMPILE and CP.BOOT; and gRJ
would list all JFBQ translations of COMPILE and
BOOT, thus being ready to use for e.g. View ->
Documentation Indices.

Since the return value is a ClassPath, you would
not need a separate change firing API; you can
listen to CP.roots as usual.

Also GPR.fR would be unnecessary since you could
use the CP methods to do this.
Comment 1 Tomas Zezula 2004-06-17 07:56:03 UTC
Sounds good to me.
The returned ClassPath is fine for gerRelevantSources() but a bit
strange for getRelevantJavadoc().
Comment 2 Jesse Glick 2004-06-17 17:05:44 UTC
True, it would look weird for getRelevantJavadoc. It would work
correctly I think.