Re: RE : [Flashcoders] create object with getDefinition and pass parameters using apply ?

2009-01-09 Thread Nate Beck
t! But at least > > it works, it could have been worse... > > > > -Original Message- > > From: flashcoders-boun...@chattyfig.figleaf.com [mailto: > > flashcoders-boun...@chattyfig.figleaf.com] On Behalf Of Nate Beck > > Sent: Friday, January 09, 2009 11

Re: RE : [Flashcoders] create object with getDefinition and pass parameters using apply ?

2009-01-09 Thread Joel Stransky
riday, January 09, 2009 11:33 AM > To: Flash Coders List > Subject: Re: RE : [Flashcoders] create object with getDefinition and pass > parameters using apply ? > > Hey Patrick, > I've run into the exact same issue that you have. Actionscript doesn't > support overl

RE: RE : [Flashcoders] create object with getDefinition and pass parameters using apply ?

2009-01-09 Thread Patrick Matte | BLITZ
:33 AM To: Flash Coders List Subject: Re: RE : [Flashcoders] create object with getDefinition and pass parameters using apply ? Hey Patrick, I've run into the exact same issue that you have. Actionscript doesn't support overloaded methods or constructors at this time, although there is

Re: RE : [Flashcoders] create object with getDefinition and pass parameters using apply ?

2009-01-09 Thread Nate Beck
_ > De : flashcoders-boun...@chattyfig.figleaf.com [ > flashcoders-boun...@chattyfig.figleaf.com] de la part de Joel Stransky [ > stranskydes...@gmail.com] > Date d'envoi : 8 janvier 2009 20:28 > À : Flash Coders List > Objet : Re: [Flashcoders] create object with getDefinition and pass >

RE : [Flashcoders] create object with getDefinition and pass parameters using apply ?

2009-01-08 Thread Patrick Matte | BLITZ
rt de Joel Stransky [stranskydes...@gmail.com] Date d'envoi : 8 janvier 2009 20:28 À : Flash Coders List Objet : Re: [Flashcoders] create object with getDefinition and pass parameters using apply ? Why not predefine the params as null? class myClass{ public function myClass(param1 = null

Re: [Flashcoders] create object with getDefinition and pass parameters using apply ?

2009-01-08 Thread Joel Stransky
Why not predefine the params as null? class myClass{ public function myClass(param1 = null, param2 = null, ... param6 = null){ } } or just use the rest (...) parameter class myClass{ public function myClass(...args){ for(var i:uint = 0; i < args.length; i++){ trace(args[i]);

RE: [Flashcoders] create object with getDefinition and pass parameters using apply ?

2009-01-08 Thread Patrick Matte | BLITZ
Well for now I've done this which supports up to 5 arguments but if anyone's got a better suggestion please tell me... var classReference:Object = getDefinitionByName(className); var object:Object; switch(array.length) { case 0: object = new classReference(); break