Hey there,
Thanks for your suggestions, seeing the memory leaks that loading modules into the same application domain yields I guess its important to resolve this issue a.s.a.p.
I've been experimenting a little with loading modules and stagewiring them. The ClassUtils in as3commmons lang actually give you the opportunity to pass an applicationdomain when retrieving a Class instance for an objectdefinition.
So, what I basically do in the stagewiring is this:
Code:
var appDomain:ApplicationDomain = (object is DisplayObject) ? (object as DisplayObject).loaderInfo.applicationDomain : null;
var cls:Class = ClassUtils.forInstance(object,appDomain);
Too bad this still came up with an error, then I dropped Spring Actionscript alltogether, just loaded a module into a test application and ran this code in the Module instance:
('this' is the Module instance)
Code:
var appDomain:ApplicationDomain = this.loaderInfo.applicationDomain;
var className:String = getQualifiedClassName(this);
var b:Boolean = appDomain.hasDefinition(className);
Guess what, b == false!
I'm rather stumped to be honest...
Any suggestions are more than welcome.
thanx,
Roland