ABSTRACT

You can use it like a normal class, because when Flash compiles the SWF, it will be a normal class, just as though you’d written it yourself.

classes that followed a numeric sequence — say, for the purposes of our example, “ square1 ” through “ square10. ” It would be very tedious to have to instantiate them one at a time and create a lot of extra code. It would probably look something like this:

Luckily , Flash gives us the ability to look up a class by its name. In the fl ash.utils package there is a method called getDefi nitionByName , which accepts said name as a string parameter.