Wednesday, August 05, 2009

Actionscript 3's ApplicationDomain Oddities 1

I have beeing doing lots of work around ApplicationDomain recently,
And there is so little information about this class (other then the realy good but not sufficiant and somewhat old post by Roger Gonzalez ).

so here goes odditie 1:

trace(ApplicationDomain.currentDomain == ApplicationDomain.currentDomain)
and
trace(ApplicationDomain.currentDomain === ApplicationDomain.currentDomain)

both trace out false.


Well, I guess the reason is that each time you access ApplicationDomain.currentDomain it create a new object that represents the currentDomain and you can use each of them for getDefinition but WHY ?! is it so.

maybe Rogger or one of his friends would like to comment on this ?

remember :

"The definition of ApplicationDomain.currentDomain is the ApplicationDomain that contains the code that is calling ApplicationDomain.currentDomain."

No comments:

 
Clicky Web Analytics