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 10534 - setSuperclass doesn't set correct name when passed parameter identifies an inner class
Summary: setSuperclass doesn't set correct name when passed parameter identifies an in...
Status: CLOSED INVALID
Alias: None
Product: java
Classification: Unclassified
Component: Unsupported (show other bugs)
Version: 3.x
Hardware: PC Windows ME/2000
: P3 blocker (vote)
Assignee: issues@java
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2001-03-21 13:08 UTC by Vitezslav Stejskal
Modified: 2007-09-26 09:14 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
junit test (2.99 KB, application/octet-stream)
2001-03-21 13:43 UTC, Vitezslav Stejskal
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Vitezslav Stejskal 2001-03-21 13:08:23 UTC
When setting super class name to some public static inner class, just a short
name is used instead of outer-class.inner-class. Generated code is not 
compilable.
Comment 1 Vitezslav Stejskal 2001-03-21 13:43:54 UTC
Created attachment 841 [details]
junit test
Comment 2 Svata Dedic 2001-03-21 13:57:33 UTC
As I understand the test source, you have some existing inner class coded as

public class OuterClass {
	public class InnerClass {
	}
}

then theInnerClassElement.getName() has sourceName property = "InnerClass", and
its fullName property should be set to "whatever.package.OuterClass.InnerClass".

The superclass property is just an identifier, nothing more - you, as the
caller, are responsible for translating the name into appropriate target context
(e.g. prefix it with outerclass/package). If you want to be sure, the best is
maybe create Identifier from the inner class' full name.
Comment 3 Quality Engineering 2003-07-01 13:12:46 UTC
Resolved for 3.3.x or earlier, no new info since then -> closing.
Comment 4 Quality Engineering 2003-07-01 13:18:05 UTC
Resolved for 3.4.x or earlier, no new info since then -> closing.