History | Log In     View a printable version of the current page.  
Issue Details (XML)

Key: FB-12172
Type: Bug Bug
Status: Community Community
Assignee: Rebecca Hauck
Reporter: Joshua Mostafa
Votes: 0
Watchers: 1
Operations

If you were logged in you would be able to see more operations.
Flash Builder / Flex Builder

Unnecessary methods added on class creation when extending a class that implements an interface that is also being implemented by the subclass

Created: 02/28/08 07:02 PM   Updated: 01/21/09 07:11 PM
Component/s: Class Wizard
Security Level: Public (All JIRA Users )

Severity: Incorrectly Functioning with Workaround
Reproducibility: Every Time
Discoverability: Medium
Found in Version: 3.0 (Released) - 194161
Affected OS(s): Windows - XP
Steps to Reproduce:
(This is a little complicated so please bear with me.)

Steps to reproduce:
1. Create an interface Foo that extends an interface (e.g., IEventDispatcher, because objects of this type must be able able to dispatch events to listeners)
2. Create a class Bar that implements Foo and extends a class (e.g., EventDispatcher) that also implements the interface that Foo extends
 
 Actual Results:
 The class creation wizard just adds all the unnecssary methods from IEventDispatcher and then the editor shows 1024 errors (overriding methods without marking for override)

 Expected Results:
 The class creation wizard should check all the methods that are *already* in place, by extending the class (e.g., addEventListener has been inherited from EventDispatcher) and any of the same methods in the interface should be ignored.
 
 Workaround (if any):
 You can just delete the methods. But it makes Flex Builder look like it's malfunctioning. You shouldn't get errors from code produced automatically.
 
Note:
You might ask, isn't it redundant for the developer to be implementing IEventDispatcher if s/he is also extending EventDispatcher? Think again. Our class Bar does not directly implement IEventDispatcher. It implements Foo. So the relationship is indirect. I need Foo to inherit from IEventDispatcher so that I can later deal with objects of type Foo without ever needing what actual class has implemented Foo.
Language Found: English
Bugbase Id: none
QA Owner: Rebecca Hauck
Participants: Joshua Mostafa and Rebecca Hauck
Eclipse Configuration: FB Standalone
JDK: Sun 1.6.x
UI Change Needed: No


 All   Comments      Sort Order:
Joshua Mostafa - [02/28/08 07:11 PM ]
By the way - I am not sure about the version. I am running a version I downloaded after the official launch. I wouldn't imagine this would be called RC anything, because it has actually been released ... but, the build number is definitely 194161, so I guess it must be right.

Joshua Mostafa - [01/21/09 07:11 PM ]
I had mis-titled the "expected" and "actual" results in the bug description - I've corrected that now.