I am slowly moving from inheritance to composition for a specific project,
one way to "extend" my classes is by creating a copy of them into the new
created classes...

class OriginalClass {

var mc:MovieClip;

function original(mc:MovieClip) {
 this.mc = mc;
 init();
};

function init() {
 trace("original");
}

------ now trying to overwrite init

class CopyClass {

var original : OriginalClass;
var mc : MovieClip;

function CopyClass(mc:MovieClip) {
this.mc = mc;
original = new OriginalClass(mc);

}

//How do I access init from the original class? I know that doing
inheritance I can just declare a new init method in my CopyClass but in this
case it doesnt work that way.

TIA
_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

Reply via email to