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 30457 - [interface synch] Interface methods added to private classes as package-private
Summary: [interface synch] Interface methods added to private classes as package-private
Status: RESOLVED FIXED
Alias: None
Product: java
Classification: Unclassified
Component: Unsupported (show other bugs)
Version: 3.x
Hardware: PC Linux
: P3 blocker (vote)
Assignee: Svata Dedic
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-01-28 22:00 UTC by Jesse Glick
Modified: 2007-09-26 09:14 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 Jesse Glick 2003-01-28 22:00:45 UTC
[dev jan 27] Create a public class. Create an
empty private static nested class. Make the nested
class implement e.g. java.util.Observer. When the
dialog appears asking you to add the method
update(...), accept. Added as package-private (no
access modifier), when it should be public to
satisfy the interface.
Comment 1 Jan Lahoda 2003-01-29 09:04:24 UTC
Probably problem of Java module.
Comment 2 Svata Dedic 2003-02-06 18:41:54 UTC
Yes; this happens specifically when source for the interface is 
mounted and the `public' access is implicit (== is not specified in the 
source).  
 
Fixed in trunk: 
/cvs/java/src/org/netbeans/modules/java/codesync/ClassDependencyImpl.java,v  
<--  ClassDependencyImpl.java 
new revision: 1.27; previous revision: 1.26 
 
Comment 3 Jesse Glick 2003-02-06 18:54:10 UTC
Note that specifying any modifiers (public, abstract) on interface
methods is discouraged (only accidentally permitted in JLS 1.0), so
the *normal* case should be to have no modifiers.
Comment 4 Svata Dedic 2003-02-06 20:42:46 UTC
Yes, of course. My point was that the bug only appears when the IDE 
has access to the interface's source. .class files always contain public 
access flag.