• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

ApplicationDomain - Adobe ActionScript® 3 (AS3 ) API Reference

Explorer ,
Mar 31, 2014 Mar 31, 2014

Copy link to clipboard

Copied

TOPICS
ActionScript

Views

276

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Mar 31, 2014 Mar 31, 2014

Copy link to clipboard

Copied

LATEST

A few issues here. As of March 31, 2014, the getQualifiedDefinitionNames method from Flash Player 11.3 is still not documented. ApplicationDomain instances have no reference equality and no public identifiers of any kind to check whether one ApplicationDomain instance refers to the same application domain as another instance (e.g. ApplicationDomain.currentDomain != ApplicationDomain.currentDomain, and there is not ApplicationDomain.ID property). That makes it difficult to cache the results of getQualifiedDefinitionNames, because I cannot create any usable key for the application domain.

Also you need to mention things like the scope of the getDefinition and hasDefinition method, in particular, that they return classes in the app domain which is the target of the call, but also definitions in container/parent domains all the way to the root/system domain. getQualifiedDefinitionNames, on the other hand, returns definitions in the target domain exclusively and does not return definitions in parent domains.

More importantly, hasDefinition will actually return false on a newly constructed ApplicationDomain, even if the definition is in its inheritance chain, such as a system class like flash.display.DisplayObject, but it will return true only after the domain has been assigned to a loader context and content has been loaded into it, activating the domain. Until the new ApplicationDomain has been activated through some kind of load, its hasDefinition/getDefinition methods fail.

Finally, the related flash.utils.getDefinitionByName needs additional documentation stating that its scope (i.e. the classes it can see or access), is the same as ApplicationDomain.currentDomain.getDefinition (i.e. the current application domain only and all its parent domains, but not sibling domains).

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines