what is the other way of using Inheritance in flash?

Answer Posted / p.suman

Well, "prototype" in AS1 or in general used to defined
member function of a class outside its definition.

Interface classes provide pure virtual functions for the
concrete classes to implement on them resulting a greater
flexibility in reusable code.

In Flash the otherway of using inheritance is to use the
key word "Extends" , which will give the properties and
methods of a base class to its subclasses.

Ex:

class myMovie extends MovieClip{
public function myMovie(){
}
}

Here myMovie class derives all the available properties of
a MovieClip class.

Regards,
Suman.P
Module Lead

Is This Answer Correct ?    7 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Tell me what are the features involved in updating a language?

534


Tell me what are the different ways in which the variables can be assigned?

494


what methods are used to pass variables out of flash to a server side solution? : Adobe flash

472


Explain what does the void function and object contain in actionscript?

471


what appears in the output window after executing this actionscript on the first frame of a movie? : Adobe flash

452






where is the data pulled by a load variables function stored? : Adobe flash

483


Which is the quickest way to make the stroke around an oval shape into a dotted line? : Adobe flash

483


which of the methods provedes the most controlled printing of flash content? : Adobe flash

460


How to write a program to show the external actionscript?

439


Differentiate between as2 and as3.

509


which text anti-aliasing property setting will result in the smallest swf file size? : Adobe flash

496


How to create a logo using pen tool?

455


what is the key advantage of flash being a true clientside application? : Adobe flash

471


How many menus will you find on the menu bar?

503


what are the steps is not required in order to test or deploy flash remoting? : Adobe flash

481