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 8320 - ClassElement can not generate interface
Summary: ClassElement can not generate interface
Status: CLOSED INVALID
Alias: None
Product: java
Classification: Unclassified
Component: Unsupported (show other bugs)
Version: -FFJ-
Hardware: PC Linux
: P4 normal (vote)
Assignee: issues@java
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2000-11-09 14:27 UTC by _ pkuzel
Modified: 2007-09-26 09:14 UTC (History)
1 user (show)

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 _ pkuzel 2000-11-09 14:27:20 UTC
[1141] I can not generate interface using ClassElement.

  classElement.setModifiers(Modifier.PUBLIC | Modifier.INTERFACE);

produces

  public interface class
Comment 1 Svata Dedic 2000-11-09 14:34:59 UTC
setModifiers was not meant for THAT type of change, really. It should, however
throw a SourceException on you instead of creating invalid code.
Please use ClassElement.setClassOrInterface(false); to turn the class element ot
an interface (set to true if you want it to be a class - this is the default
value).
Comment 2 _ pkuzel 2000-11-09 15:01:59 UTC
Why do not deprecate setClassOrInterface(boolean)?
Comment 3 Quality Engineering 2003-07-01 13:12:01 UTC
Resolved for 3.3.x or earlier, no new info since then -> closing.
Comment 4 Quality Engineering 2003-07-01 13:16:07 UTC
Resolved for 3.4.x or earlier, no new info since then -> closing.